local i = 1while t[i] ~= nil do local v = t[i] -- do some stuff here i = i+1end(Also faster than using ipairs())