11 lines
249 B
Text
11 lines
249 B
Text
|
|
class MAIN is
|
||
|
|
main is
|
||
|
|
num:ARRAY{INT} := |1, 5, 4, 3, 10|;
|
||
|
|
loop
|
||
|
|
-- the iterator elt! behaves like a "foreach",
|
||
|
|
-- yielding the next element of the array at each iteration
|
||
|
|
#OUT + num.elt! + "\n";
|
||
|
|
end;
|
||
|
|
end;
|
||
|
|
end;
|