Ok, so I use for i, v in pairs(T) quite a bit. But what if I want to reverse the order? Can you add a step in the pairs loop, or a negative step?

2 comments

0

You could do (#T-i)+1 I think

0

I can't seem to figure out the pairs equivalent, i tried some variations of that, but for now, I just went with a generic index iterator: `` for i = #bl, 1, -1 do; v = tbl[i]; end