Just saw this in the Lua self examples...
-- Example 24 -- Printing tables.
-- Simple way to print tables.
a={1,2,3,4,"five","elephant", "mouse"}
for i,v in pairs(a) do print(i,v) end
-------- Output ------
1 1
2 2
3 3
4 4
5 five
6 elephant
7 mouse
Press 'Enter' key for next example
I haven't seen this syntax before, for i,v in pairs(a) do print(i,v) end
Where did the v come into existence ?
Does the word in cause it to exist ?
By the same token, where does the i come into existence ?
Is this a syntax designed for tables ?
Thanks for any explanation.