| Bytes | Lang | Time | Link |
|---|---|---|---|
| 053 | AWK | 250806T162500Z | xrs |
| 064 | JavaScript V8 | 250728T045057Z | Steve Be |
| 229 | Bespoke | 250727T134447Z | Josiah W |
| 053 | Setanta | 240802T174156Z | bb94 |
| 076 | brainfuck | 240802T062252Z | Andrew B |
| 026 | Knight | 220807T092530Z | Aiden Ch |
| 001 | Vyxal | 210531T091152Z | emanresu |
| 001 | BRASCA | 210507T140002Z | SjoerdPe |
| 023 | batch | 210507T131230Z | T3RR0R |
| 026 | Excel | 210316T215652Z | Axuary |
| 006 | Factor | 210316T231500Z | Michael |
| nan | Pxem | 210317T130959Z | user1004 |
| 001 | 05AB1E | 201210T224157Z | Makonede |
| 004 | PowerShell Core | 210316T070309Z | mazzy |
| 208 | Java 8 | 210316T212627Z | hakr14 |
| 188 | TeX | 210316T112943Z | plante |
| 001 | Deadfish~ | 210316T105325Z | emanresu |
| 034 | PowerShell Core | 210316T004340Z | Julian |
| 003 | SmileBASIC 4 | 201212T013600Z | BMF |
| 013 | Husk | 201210T235047Z | Dominic |
| 6510 | C Preprocessor | 200725T004613Z | RobertR |
| 053 | Excel Online | 200724T211442Z | General |
| 134 | Google Sheets | 200724T185105Z | General |
| 001 | 33 | 200724T053719Z | TheOnlyM |
| 043 | x86 machine code 32bit | 200624T180904Z | anatolyg |
| 053 | Perl 5 | 200722T193515Z | Dom Hast |
| 004 | Stax | 200624T153421Z | Khuldrae |
| 001 | MAWP 0.1 | 200624T060220Z | Dion |
| 001 | 05AB1E | 200406T085641Z | Kevin Cr |
| 053 | C gcc | 200422T101420Z | l4m2 |
| 064 | Bash | 200414T145409Z | marcosm |
| 001 | PowerShell | 200411T110534Z | ScriptKi |
| 034 | Zsh | 200408T224954Z | GammaFun |
| 076 | SQL Oracle 76 Bytes | 200408T151045Z | Del |
| 043 | dirt | 200408T043046Z | cardboar |
| 053 | C gcc | 200404T212111Z | S.S. Ann |
| 043 | Io | 200405T030745Z | user9206 |
| 7611 | Java 10 | 200406T094702Z | Kevin Cr |
| 043 | PHP | 200406T090328Z | Kaddath |
| 001 | Jelly | 200405T104443Z | L. F. |
| 026 | Bash | 200405T192903Z | dingledo |
| 034 | Befunge98 FBBI | 200405T191259Z | ovs |
| 001 | HQ9+ | 200405T184814Z | S.S. Ann |
| 053 | C gcc | 200405T052623Z | dingledo |
| 076 | Clojure | 200404T233223Z | math jun |
| 019 | Perl 5 | 200404T221341Z | RaphaelQ |
| 053 | Red | 200405T075719Z | Galen Iv |
| 034 | JavaScript ES7 | 200404T222809Z | Arnauld |
| 043 | C# Visual C# Interactive Compiler | 200405T035810Z | the defa |
| 053 | Python 3 | 200405T075754Z | Dion |
| 053 | Python 3 | 200405T075421Z | RGS |
| 043 | Bash + GNU utilities | 200405T050919Z | Mitchell |
| 004 | dc | 200404T231419Z | Mitchell |
| 076 | Erlang escript | 200405T043648Z | user9206 |
| 001 | Pyth | 200404T222153Z | math jun |
| 034 | Ruby | 200405T023916Z | 79037662 |
| 001 | Canvas | 200405T023101Z | user9206 |
| 001 | Keg | 200404T232725Z | lyxal |
| 013 | Charcoal | 200404T225659Z | Neil |
| 001 | Retina | 200404T222924Z | math jun |
| 043 | Python 2 | 200404T222202Z | dingledo |
| 034 | R | 200404T221912Z | Robin Ry |
| 053 | Haskell | 200404T215753Z | Wheat Wi |
| 001 | Japt | 200404T220046Z | Shaggy |
| 043 | Wolfram Language Mathematica | 200404T215448Z | ZaMoC |
| 001 | brainfuck | 200404T213722Z | S.S. Ann |
AWK, 53 bytes
{
um
x--
s=$0
x+=11
do{x--
print s
s=s"\\"}
while(x)}
Takes a char as input and uses that to print.
A
A\
A\\
A\\\
A\\\\
A\\\\\
A\\\\\\
A\\\\\\\
A\\\\\\\\
A\\\\\\\\\
JavaScript (V8), 64 bytes
(
_,
)=>
[01,
10,1+
99,!0,
!1,1e5,
1e6,1/0,
_+'',10e8
].join`\n`
There are surely shorter ways, but I enjoyed just constructing an array of lines of the correct length.
Output:
1
10
100
true
false
100000
1000000
Infinity
undefined
1000000000
Bespoke, 229 bytes
1
23
Now
I go
"Am I
near a
slanted
pyramid?
I'm here,
seeing one
bit of a...
a triangle."
Triangles: an
idea old as we
can remember...
though, why is a
triangular figure
in this paragraph?
Somebody likes this
shape terribly much.
Prints the first 20 powers of 11.
Setanta, 53 bytes
Theoretically the shortest, as at least one line must contain scriobh(.
0
le
i
idir
(1 ,
10)>--
>------
scriobh(
"." * i)
brainfuck, 76 bytes
+
++
+++
++++
>->++
++++++
+++[->+
[->+>+<<
]>[-<+>]>
[-<<<<.>>>
>]<<<<<.>>]
Vyxal, 1 byte
0
Any digit works.
More interestingly,
Vyxal j, 4 bytes
2
ʁ↵
2 # 2
ʁ # Range 0-1
↵ # 10 ** n (vectorised)
# (j flag) joined by newlines
Using powers of 10.
And finally,
Vyxal, 8 bytes
3
ɾ×
*⁋,
3 # 3
ɾ # 1...3
×* # That many asterisks, for each
⁋ # Joined by newlines
, # Outputted.
Making an asterisk triangle.
BRASCA, 1 byte
Yep, it's another one of these.
Pick any one of these:
0123456789oOnNlLeEdDhHK+-*^s}r&|_ABmM?!ST<>=Y
Explanation
TL;DR: Most instructions work because an empty stack consists of infinite zeroes.
0-9 - Pushes the digit, implicit output.
oOnN - Prints the top/bottom of the stack, which is 0x00 because the stack is empty.
lLeEdDhHK - Pushes 10, 13, 26, 32, 48, 65, 97, 100 and 1000 respectively, implicit output.
+-*^s} - Operate on zeroes because of an empty stack. (ex. + on an empty stack is 0+0).
r - Pushes a range between 0 and 0, which is just a single 0.
&|_ - Bitwise operators on zeroes because, once again, of an empty stack.
AB - Registers are 0 by default.
mM - Shifting an empty stack pushes a 0.
? - Pushes a random number between 0 and 0.
! - Pushes the stack length, which is 0.
S - Concatenates 0 with 0, creating 0.
T - Sets implicit output to only output the top of the stack, which is empty, so it's a 0.
<>=Y - Compares 0 with 0 in a bunch of ways.
batch 63 23 bytes
:
T^
YP^
E==^
;%~f0
Outputs the file content.
Note:
- TIO not available, run it from the command line after turning
echo off
Excel, 26 bytes
=
7^
(((
ROW(
1:6))
))&""
Below is 17 bytes but Excel removes the line feeds in the array after I hit enter and the output is right justified.
=
3^
{2;
4;6;
8;10}
Factor, 34 26 bytes (7 6 lines)
-8 bytes / 1 line thanks to Bubbler!
10
6
iota
n^v
stack.
Output:
1
10
100
1000
10000
100000
Pxem, Filename: 103 bytes + Content: 0 bytes = 103 bytes
Filename as follows (if your filesystem doesn't support LF, I'm sorry) (also requires to be ASCII-compatible):
x
.p
x.n
.o.n
.o04x
.-.t.z
.c.zxxx
.a.m.m.w
.sx.oab.-
.s.-.c.a.s
.c.o.c.$.mx
.s.s.+.tao.-
.s.m.a.dxxxxx
Content is empty.
Output
x
10
120
xxxx
xxxxx
xxxxxx
xxxxxxx
xxxxxxxx
xxxxxxxxx
xxxxxxxxxx
xxxxxxxxxxx
xxxxxxxxxxxx
xxxxxxxxxxxxx
With comments
Note that every LF is replaced with '?'.
x?.pXX.z # print'x', LF
.a?x.nXX.z # print LF.ord # two-digits
.a?.oXX.z # print LF
.a.n?.sXX.z
.a04x?.-.tXX.z # i = 4
.a.zXX.z # loop
.a?.c.zxxx?.aXX.z # essentially nop
.a.m.m.wXX.z # j = i; while j!=0
.a?.sx.oXX.z # print'x'
.aab.-?.s.-.cXX.z # j--
.a.a.s?.c.oXX.z # end-while; print LF
.a.c.$.mx?.s.s.+.tXX.z # i++
.aao.-?.s.mXX.z # break if !(14>i)
.a.a.dxxxxx # end-loop; end program
05AB1E, 1 byte
Any one of 0123456789@NQXY_adg‹›¾ÊËåð will work. They will output one of 0123456789101120000000011 respectively.
PowerShell Core, 4 bytes
Trivial power (up to 19 lines)
1
10
PowerShell Core, 4 bytes
p–n junction (90 variants)
1
-1
PowerShell Core, 26 bytes
Twinkle, twinkle, little star
,
'*
*'*
6|%{
'*' *
++$ko}
PowerShell Core, 26 bytes
The magic number in nuclear physics and the quark soup of 3 quarks $_
,
1+
2..
6|%{
"$_"*
$_};$_
Java 8, 208 bytes
;
/*
who
they
are*/
public
class//
Main{//h
public //
static//14
void main//
(String[]ar)
{for(int i=0;
i<19;i++){for(
int j=0;j<i+1;j
++) System.out.
//crucial comment
print('*');System.
out.println();}}}//
A triangular full program.
TeX, 188 bytes
Nothing out of the ordinary, but for completeness:
%
%%
%%%
%%%%
%%%%%
%%%%%%
%%%%%%%
%%%%%%%%
\countdef
~=1%%%%%%%
\countdef%%
\i=26\loop%%
\advance~1{%%
\loop\advance%
\i1.\ifnum\i<~%
\repeat\endgraf}
\ifnum~<18\repeat
\bye%%%%%%%%%%%%%%
Deadfish~, 1 byte
o
Outputs
0
This is kind of cheating but I can't think of any other way to do it in Deadfish~.
PowerShell Core, 103 53 34 bytes
#
##
$n`
=1;`
$n..`
7|%{(`
$n*=9)}
A Powershell port of the R solution by Robin Ryder, thanks!
SmileBASIC 4, 3 bytes
\
?0
0
OK
Husk, 13 bytes
₁
¶₂
ΘI₃
↑3İ⁰
No comment characters, so every element does something...
₁ # run function on line 1 (next line)
¶₂ # split output of function on line 2 (next line)
ΘI₃ # prepend zero to identity of function on line 3 (next line)
↑3İ⁰ # first 3 elements of powers of 10
Husk, 1 byte
Trivial (but included for completeness)
1
(there are many more like this... all equally uninteresting...)
C Preprocessor, 65 bytes (10 lines)
.
..
...
....
.....
......
.......
........
.........
__TIME__//
Process with GCC/Clang with -E and -P options. (Thanks to Calculuswhiz for suggesting the -P option.)
All the dots are ignored. The predefined __TIME__ macro expands to a string of the form "HH:MM:SS", meaning the last line stays the same length.
Excel Online, 53
9 lines
=
T(
12*
34)&
REPT(
0,ROW(
OFFSET(
A1,,,9))
)&TEXT(,)
How It Works
Kind of like my Google Sheets answer, but the bottleneck is the REPT() instead.
Sadly, I cannot break the function name from the open paren. Also, Excel Online does not auto-close, so we're stuck with an extra line. However, some nice things that did help were that Excel Online detects Array Formulas automatically, and it displays Array elements as separate rows, so I get a free line break.
Google Sheets, 134
15 lines
=
T(
(--
CODE
("owo
(^_^;)
orz")))
&RIGHT(,
)&LEFT(,)
&MID(,1,)&
IF(LN(2),)&
ARRAYFORMULA
(JOIN(CHAR(10
),,REPT(0,ROW(
OFFSET(A1,,,15)
How It Works
Stall until we have a long enough line for ARRAYFORMULA, then catch up by generating 15 rows of an increasing number of 0's using REPT() and ROW(OFFSET()) and joining them together with JOIN(). Google Sheets will auto-close the missing parens.
Notes
- Hey, look! No duplicate literals, no duplicate function calls, and no spaces. I could have strung together a bunch of
""&s, but that would be less entertaining. - The bottleneck here is
ArrayFormula, so unless there's a way around that, I think we're stuck.
33, 1 byte
o
o prints the value of the accumulator, which defaults to 0.
Bit boring, but what can you do about it.
x86 machine code (32-bit), 43 bytes
As symbols in codepage 437:
`
!Q
!j
!Y_j
Q░x≤¬
'YX¬A╢
Ç∙ëq∞Çε
ê7af║█¡├
Hexdump:
600a
21510a
216a010a
21595f6a0a
51b078f3aa0a
275958aa41b60a
80f98971ec80ee0a
88376166badbadc3
A fastcall function which receives the pointer to output buffer in ecx. It fills the buffer with a triangle containing the letter x:
x
xx
xxx
xxxx
xxxxx
xxxxxx
xxxxxxx
xxxxxxxx
Disassembly:
10013FF0 60 pushad
10013FF1 0A 21 or ah,byte ptr [ecx]
10013FF3 51 push ecx
10013FF4 0A 21 or ah,byte ptr [ecx]
10013FF6 6A 01 push 1
10013FF8 0A 21 or ah,byte ptr [ecx]
10013FFA 59 pop ecx
10013FFB 5F pop edi
10013FFC 6A 0A push 0Ah
10013FFE 51 push ecx
10013FFF B0 78 mov al,78h
10014001 F3 AA rep stos byte ptr es:[edi]
10014003 0A 27 or ah,byte ptr [edi]
10014005 59 pop ecx
10014006 58 pop eax
10014007 AA stos byte ptr es:[edi]
10014008 41 inc ecx
10014009 B6 0A mov dh,0Ah
1001400B 80 F9 89 cmp cl,89h
1001400E 71 EC jno again (10013FFCh)
10014010 80 EE 0A sub dh,0Ah
10014013 88 37 mov byte ptr [edi],dh
10014015 61 popad
10014016 66 BA DB AD mov dx,0ADDBh
1001401A C3 ret
I used various instructions to insert a new-line byte 0A into the machine code:
10013FF1 0A 21 or ah,byte ptr [ecx]
10014009 B6 0A mov dh,0Ah
10014010 80 EE 0A sub dh,0Ah
At the end of the program, I needed to pad it with 4 bytes. I used a harmless MOV command instead of 4 NOPs so I could have hexadecimal BADBAD in code.
Stax, 4 bytes
2
mR
Run and debug it at staxlang.xyz!
Nontrivial solution. Prints "\x01\n\x01\x02", so you won't see any output, but it's there. One byte is easy but boring.
2 Push 2
mR For n in [1,2], print [1..n] as a string
Another 4-byter that feels like cheating:
0 Do nothing
|? Source of program, implicit print.
05AB1E, 1 bytes
0
Not much to say I guess..
If this was code-bowling instead, we could do something like this (can be made as arbitrary large as you'd want it to, as long as the last three bytes are ₄*»):
1
11
111
1111
11111
111111
1111111
11111111
111111111
1111111₄*»
Explanation:
1\n11\n111\n... # Push all these numbers one by one to the stack
111...111 # Push the number of the last line
₄* # Multiply it by 1000 to increase its size by 3
» # Join everything on the stack by newlines
# (after which it is output implicitly as result)
C (gcc), 53 bytes
\
m\
ain
(n){
for(;
9/n;n=
printf(
"%0*d\n"
,n,0));;}
C (gcc), 53 bytes
\
m\
ain
(n){
9/n&&
main(\
printf(
"%0*d\n"
,n,0));;}
Bash, 64 bytes
\
d\
at\
e +\
d%n%\
m%n%j\
%n%Y%n\
%R%n%:z\
%n%7Y%n%\
T%n%N%n%F\
Not the shortest but kind of fancy. Displays current date in convinient format. Tried to do it locales intependent. Last byte for fancy too.
PowerShell, 1 byte
0
Try it online ->
Very similar to other answers, shocked that no one posted this before.
Zsh, 34 bytes
:
r\
ep\
eat\
7 {:
s+=A;:
<<<$s;}
After re-joining lines:
: # ':' is a no-op, just to fill space more visibly than ' '
repeat 7 {
:
s+=A
:
<<< $s
}
SQL (Oracle) 88 76 Bytes
;
/*
ABC
DEFG
HIJ*/
SELECT
LPAD(1,
LEVEL,1)
FROM DUAL
CONNECT BY
LEVEL < 12;
Output:
1
11
111
1111
11111
111111
1111111
11111111
111111111
1111111111
11111111111
Edit: Thanks @Math Junkie, by following the rules I actually cut off 12 bytes.
dirt, 43 bytes
x
xx
xx|
|'a'
(a*'a
)**{1|
}.*|"11
11111"|x
run with with empty string as input:
>dirt triangle.dirt -i ""
a
aa
aaa
aaaa
aaaaa
aaaaaa
aaaaaaa
aaaaaaaa
Io, 43 bytes
A lot more "content" than my previous submissions.
\
\
\
for(
i,1,8
,(9**i
) \
println)
Java 10, 76 bytes (11 rows)
v
->
{//
var
r="";
long i
=0,s=1;
for(;++i
<12;r+=(s
*=9)+"\n")
;return r;}
Inspired by all the other answers.
PHP, 43 bytes
;
1;
for
(;$i
++<8;
)echo(
10**$i-
1)."\n";
Not that bad for PHP.. displays a triangle of "9"
Jelly, 1 byte
0
The vast majority of atoms can be used for this, printing 0 or 1. The few exceptions are listed as follows: (incomplete, didn't check past Ẓ in the Atoms page)
³⁴⁵⁹: prints more than one digit½°: prints0.0~: prints-1⁷: prints\n⁸IRḶṬẈ: prints nothingMTZ: errorsƓƈɠ: interacts with STDIN
Borderline:
(allowed per S.S. Anne's comment)Ọ: prints null character
Bash, 26 bytes
The dc command turns out to be quite useful in code-golfing.
\
d\
c \
-e{\
5..1\
0}*p \
Befunge-98 (FBBI), 34 bytes
Outputs \$ 9^k, 1 \leq k \leq 7 \$.
v
8v
<v1
v< @
> 9*v
.^ >\:
a,:|>1-
The first three lines
v
8v
<v1
push 8 (loop counter) and 1 (\$ 9^0 \$). The main loop can be written in a single line as
9*\1-a,:!#@_\:.
9* multiply by 9
\ swap to loop counter
1- subtract 1
a, output newline
:! duplicate and invert loop counter
#@_ quit if non-zero, continue east otherwise
\ swap to 9^k
:. duplicate and output 9^k
C (gcc), 53 bytes
Fixed error pointed out by @S.S. Anne
\
m\
ain
(n){
9<pr\
intf(\
"%d\n",
n*=9)||\
main(n);}
Clojure, 103 89 76 bytes
(
;;
;;;
loop
[i 9]
(when(
* i;;;;
99999999
)(println
i)(recur(*
i 9))));;;;
Prints the first 11 powers of 9. Exits with an ArithmeticException: integer overflow when trying to multiply \$9^{12}\$ by \$99999999\$.
Perl 5, 66 54 53 19 bytes
#
##
use
####
Quine
I am submitting this as a joke because I did not even bother trying to write some optimized code. Instead, I am using a module from CPAN that causes the program to print itself.
The Quine.pm module can be found on CPAN and was released in January 2001, long before this question was posted here. So I assume that it is acceptable, as it seems to be the tradition in other Code Golf questions.
Edit 1: Saved 12 bytes by removing the semicolon after the use statement.
Edit 2: Thanks to Arnauld for pointing out that I did not need the final newline character, saving one byte.
Edit 3: Thanks to petStorm who made a great improvement by putting the use statement and the module name on separate lines, reducing the program to only 19 bytes. This exercise that started as a joke is now a very competitive entry. It would be difficult to do better in a non-obscure language (insert joke about Perl's readability here).
Red, 53 bytes
;
t:
"*"
loop
( 9)[
print(
(( t)))
insert((
t))1 + 7]
Red, 76 64 bytes
;
s:
{t:
"*"
loop
(10)[p
rint(t)
insert(t
)"*"]}do
trim/all s
JavaScript (ES7), 43 34 bytes
A triangle of 7 rows, filled with 0's.
f
=(
s=`
`)=>
s[7]?
'':0+s
+f(0+s)
Commented
f // f is a recursive function
=( // taking
s=` // a string s initialized to
`)=> // a linefeed
s[7]? // if s has more than 7 characters,
'':0+s // stop recursion; otherwise append a 0, followed by s,
+f(0+s) // followed by the result of a recursive call with 0 + s
C# (Visual C# Interactive Compiler), 64 53 43 bytes
;
;;
int
s=1,
i;for
(;i++<
9;Print
(s*=9));
Simply prints the first several powers of 9.
Python 3, 64 53 bytes
#
##
###
for\
i in\
range\
(1, 9):
print(\
'.' *i )#
Removed a line by pushing two lines into one last one, saved 11 bytes
Python 3, 53 bytes
#
##
###
for\
i in\
range(
9):####
print(#
10**i)###
Try it online! Similar to dingledooper's submission. I was also going to submit:
brainfuck, 1 byte!!
.
Try it online! But S.S.Anne beat me by a couple of hours :)
Bash + GNU utilities, 43 bytes
\
s\
eq\
-f\
'seq\
-s "\
" %f' \
$[+8]|sh
I couldn't quite get this down to 7 rows; I needed to pad it by 4 bytes to fill out the 8-row triangle (that's why I have $[+8] in the code instead of just 8).
BSD Challenge!
If you take the same idea as the GNU solution above but use the BSD utility jot instead of seq, it's just one byte too long for a 7-row solution (which would be 34 bytes):
\
j\
ot\
-w\
'jot\
-s "\
" ' 7|sh
# This is one byte too long for 7 rows :( .
If someone can see how to shave just 1 byte off this BSD version, that would get it down to a 7-row 34-byte solution.
Here's a TIO link to the BSD version if anybody wants to try their hand at eliminating that one last byte! This also works under OS X, if you have a Macintosh.
(Obviously this version, like the GNU version in my main answer above, can be padded to be another 8-row 43-byte solution, but that's not as interesting.)
dc, 4 bytes
B
1f
Explanation:
B Push 11 on the stack.
1 Push 1 on the stack.
f Print the items on the stack, starting at the top, each one with a terminal newline.
Erlang (escript), 76 bytes
f
()
->[
%%%%
%%%%%
string
:copies
("!", X)
++"\n"||X
<- lists :
seq(1,11)].
Pyth, 1 byte
Z
In Pyth, Z is initialized to 0. Output is implicit so 0 will be printed
4 bytes
Z
T;
T is initialized to 10 and implicitly printed. ; is a no-op in this context.
Canvas, 1 byte
Boring solution, just like everyone else. :)
\
Canvas, 4 bytes
Non-trivial attempt.
\
2\
Explanation
\ # Draw a diagonal, with nothing on the stack
# Errors silently
# Newline: A character not in the code page.
# It basically does nothing.
2 # 2: Push 2 onto the stack
\ # Draw a diagonal with a length of 2
# Implicit output
Keg, 1 byte
t
Sorry, it's a simple literal answer. But then again, all answers in Keg are going to be simple literal answers. Works because characters auto-push and auto-print.
Here's a script that will generate a triangular source code for any given n.
Charcoal, 13 bytes
F
E⁺
.¦.
×⊕λ.
Try it online! Explanation: In Charcoal, newlines, which I will represent below with ¶, are simply parts of string literals.
F¶
Loop over the characters in the string literal ¶.
E⁺¶.¦.¶
Concatenate the string literals ¶. and .¶, loop over the characters, and print each result on its own line.
×⊕λ.
Repeat . by one more than the character index (0-indexed).
Retina, 1 byte
`
The backtick sets the configuration, which in this case is empty. By default, Retina outputs the number of matches of the regex on the input. In this case that regex is the empty string, so the output is 1
Python 2, 53 43 bytes
I think we are allowed to output different characters. Because of this, I simply printed \$10^i\$ at every iteration.
#
##
###
i=1;
exec\
"prin\
t i;i*\
=10;"*8\
R, 34 bytes
#
d=
cat
d(9^
(1:7)
,sep="
")#####
Outputs \$9^1\$ to \$9^7\$:
9
81
729
6561
59049
531441
4782969
Haskell, 76 64 53 bytes
u
=
(9
^)
<$>[
1..9]
main=
mapM_
print u
This prints the first 9 powers of 9.