Hi, from my research the gist of what I've read about pairs and ipairs is that pairs does not iterate with any determined ascending/descending order, while ipairs does. However, in practice I've tried pairs on both an array and dictionary, and simply running
local test = { john = "hey", doe = "no", yes = "oui" } for i, v in pairs(test) do print(i, v) end
prints in the same order every time. However, if I paste this exact code into an online lua compiler, it does what I'd expect - iterates with no predetermined order. Why does Roblox behave differently?

3 comments
Thanks for the link! That explains them giving identical outputs for arrays. What about dictionaries? The code in the original post uses a dictionary, and in an online lua compiler the output is random, but in Roblox Studio it's always the same. How come?
I been trying to figure out the same thing myself lol. I'm not too sure why it does that.
Lol, yea I'm really confused by it :( I could iterate randomly using another algorithm, but I'm still curious why it's working differently in Roblox compared to any other Lua compiler