Module:TableTools: Difference between revisions
Content deleted Content added
add getNumKeys function and improve the comments, add the beginnings of a sparseIpairs function |
finish sparseIpairs |
||
Line 72:
-----------------------------------------------------------------------------------
--]]
local i = 0
local lim = #nums
return function ()
i = i + 1
if i <= lim then
local key = nums[i]
return key, t[key]
end
end
end
return p
|