fork(4) download
  1. arr = {
  2. apples = { 0, 'a', "red", 5 }
  3. oranges = { 1, 'o', "orange", 12 }
  4. pears = { 2, 'p', "green", 7 }
  5. }
  6.  
  7. for k, v in pairs(arr) do
  8. print(k, v[1], v[2], v[3])
  9. end
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
luac: prog.lua:3: '}' expected (to close '{' at line 1) near 'oranges'
stdout
Standard output is empty