Kostiskat
(kostis)
#1
If I have a table, for example:
local myTable = {"Banana", "Apple", "Pear", "Watermelon"}
and I remove an element, for example:
table.remove(myTable, 1)
then do other element integers get forwarded to fill the gap print(myTable[1]) = Apple
or does it just return a nil
value?
sjr04
(uep)
#2
It will shift down, yes, which is why it may be preferable in most cases to table.remove
instead of removing it yourself (myTable[1] = nil
)
1 Like
Kostiskat
(kostis)
#3
Thanks! Really helped me out! ^^