Jump to content

Isqrt (integer square root) of X: Difference between revisions

add APL
(add APL)
Line 284:
7^15 (4,747,561,509,943): 2,178,889
7^17 (232,630,513,987,207): 15,252,229"</lang>
 
=={{header|APL}}==
<lang APL>i←⌊.5*⍨⊢</lang>
{{output}}
<pre>
i¨⍳65
1 1 1 2 2 2 2 2 3 3 3 3 3 3 3 4 4 4 4 4 4 4 4 4 5 5 5 5 5 5 5 5 5 5 5 6 6 6 6 6
 
6 6 6 6 6 6 6 6 7 7 7 7 7 7 7 7 7 7 7 7 7 7 7 8 8
 
(⎕fr⎕pp)←1287 34
↑{⍵ (7*⍵) (i 7*⍵)}¨1,1+2×⍳10
1 7 2
3 343 18
5 16807 129
7 823543 907
9 40353607 6352
11 1977326743 44467
13 96889010407 311269
15 4747561509943 2178889
17 232630513987207 15252229
19 11398895185373143 106765608
21 558545864083284007 747359260
</pre>
 
=={{header|Arturo}}==
Cookies help us deliver our services. By using our services, you agree to our use of cookies.