RosettaCodeData/Task/Multiple-distinct-objects/Oz/multiple-distinct-objects-2.oz
Ingy döt Net d066446780 langs a-z
2013-04-10 22:43:41 -07:00

7 lines
229 B
Text

declare
Arr = {Array.new 0 10 {OS.rand}} %% WRONG: contains ten times the same number
in
%% CORRECT: fill it with ten (probably) different numbers
for I in {Array.low Arr}..{Array.high Arr} do
Arr.I := {OS.rand}
end