Hailstone sequence: Difference between revisions
Content added Content deleted
m (→{{header|Wren}}: Changed to Wren S/H) |
imported>Arakov |
||
Line 3,956: | Line 3,956: | ||
=={{header|Elena}}== |
=={{header|Elena}}== |
||
ELENA |
ELENA 6.x : |
||
<syntaxhighlight lang="elena">import system'collections; |
<syntaxhighlight lang="elena">import system'collections; |
||
import extensions; |
import extensions; |
||
Line 3,995: | Line 3,995: | ||
auto recursiveLengths := new Map<int,int>(4096,4096); |
auto recursiveLengths := new Map<int,int>(4096,4096); |
||
for(int i := 1 |
for(int i := 1; i < maxNumber; i+=1) |
||
{ |
{ |
||
var chainLength := Hailstone(i, recursiveLengths); |
var chainLength := Hailstone(i, recursiveLengths); |