Smallest square that begins with n: Difference between revisions

Add FOCAL
(Added C# version)
(Add FOCAL)
Line 851:
</pre>
 
=={{header|FOCAL}}==
<lang focal>01.10 F I=1,49;D 2
01.20 Q
 
02.10 S N=1
02.20 S S=N*N
02.30 S A=S
02.40 I (A-I)2.7,2.9,2.5
02.50 S A=FITR(A/10)
02.60 G 2.4
02.70 S N=N+1
02.80 G 2.2
02.90 T %5,S,! </lang>
{{out}}
<pre style='height:16em;'>= 1
= 25
= 36
= 4
= 529
= 64
= 729
= 81
= 9
= 100
= 1156
= 121
= 1369
= 144
= 1521
= 16
= 1764
= 1849
= 196
= 2025
= 2116
= 225
= 2304
= 2401
= 25
= 2601
= 2704
= 289
= 2916
= 3025
= 3136
= 324
= 3364
= 3481
= 35344
= 36
= 3721
= 3844
= 3969
= 400
= 41209
= 4225
= 4356
= 441
= 45369
= 4624
= 4761
= 484
= 49</pre>
=={{header|FreeBASIC}}==
<lang freebasic>dim as uinteger ssq(1 to 49), count = 0, curr = 1, curr2
2,119

edits