Y
Hacker News
new
|
ask
|
show
|
jobs
by
groovy2shoes
4843 days ago
If you want the array elements to shift into the gap, you want to use table.remove:
local array = {1, 2, 3, 4} table.remove(array, 2) -- array is now { [1] = 1, [2] = 3, [3] = 4 }