In that case, you’d first need to clone the table.
local chosenNumber:number = math.random(1,#storeItems);
local tempTable = {};
for i,v in storeItems[chosenNumber] do
tempTable[i] = v;
end;
storeItems[chosenNumber] = nil;
storage[#storage + 1] = tempTable;
It’s used to assign it a type. The interpreter will interpret that this variable will always be a “number” type. It is in no ways needed at all, I am just used to it.