So I finally decided to truly learn Lua and I'm a little bit confused. From what I can tell, ipairs() seems to be more useful for iterating over a table setup as an array, for example:
arrayVar = {"Gold", "Silver", "Bronze"}
And pairs seems to be more useful for iterating over a standard table (keys and value), for example:
tableVar = {["Gold"] = 1, ["Silver"] = 2, ["Bronze"] = 3}
It appears that pairs also does well with an array style table too, but ipairs does not do well with a key-value table.
Am I on the right track or am I misunderstanding this?