lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On Sat, Mar 17, 2018 at 8:46 PM, Soni "They/Them" L. wrote:
Sparse array, lua 5.3:
setmetatable({1, 2, 3, [42] = 42, n = 42}, nlen)

Sparse array, "egorlua":
{1, 2, 3, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, 42 #}


:-)

t = {1, 2, 3, [42] = 42}
#t = 42