Take a look at the following code sample which loops through a simple list:
myList = {1,2,3} for i,v in ipairs(myList) do print(`v) end
this outputs: 1
, 2
and 3
. the reverse order print of this would be 3
, 2
, 1
.
Is it possible, in LUA, to get the reversed output WITHOUT reversing myList
and without using for i, #myList do
loop? Is there a reverseIPairs()
function or something like that?