FOREACH
This loop will repeat the function for each entry of a numbered table as if you call the function and pass the value of the table to the function.
foreach( table, function )
table |
variable name of a numbered table |
function |
a function name, without parentheses, that will be called to run repeatedly and given the value of each table entry each time it is run. |
Example Table:
HighScores | |
john | 143 |
bob | 99 |
kim | 984 |
foreach( highscores, print )
-- prints: 10 143 984
Images in this Guide by NerdyTeachers is licensed under CC BY-SA 4.0
1114
18 Mar 2023