Add tasks for all the new languages
This commit is contained in:
parent
9dc3c2bb62
commit
bba7bfd280
13208 changed files with 134745 additions and 0 deletions
18
Task/Loops-Nested/Lingo/loops-nested.lingo
Normal file
18
Task/Loops-Nested/Lingo/loops-nested.lingo
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
-- create two-dimensional array with random numbers
|
||||
a = []
|
||||
repeat with i = 1 to 20
|
||||
a[i] = []
|
||||
repeat with j = 1 to 20
|
||||
a[i][j] = random(20)
|
||||
end repeat
|
||||
end repeat
|
||||
|
||||
-- iterate over rows and columns, print value, exit both loops if it's 20
|
||||
repeat with i = 1 to 20
|
||||
repeat with j = 1 to 20
|
||||
v = a[i][j]
|
||||
put v
|
||||
if v=20 then exit repeat
|
||||
end repeat
|
||||
if v=20 then exit repeat
|
||||
end repeat
|
||||
Loading…
Add table
Add a link
Reference in a new issue