Show the (decimal) value of a number of 1s appended with a 3, then squared: Difference between revisions
Show the (decimal) value of a number of 1s appended with a 3, then squared (view source)
Revision as of 14:11, 15 April 2022
, 2 years agoAdded Arturo implementation
Not a robot (talk | contribs) (Add COBOL) |
Drkameleon (talk | contribs) (Added Arturo implementation) |
||
Line 135:
111 AAAAAAAAAAAA12387654320ZZZZZZZZZZZ98769
</pre>
=={{header|Arturo}}==
<lang rebol>loop 0..7 'x [
num: to :integer(repeat "1" x) ++ "3"
print [num num^2]
]</lang>
{{out}}
<pre>3 9
13 169
113 12769
1113 1238769
11113 123498769
111113 12346098769
1111113 1234572098769
11111113 123456832098769</pre>
=={{header|AWK}}==
<lang AWK>
|