I need print full table but dont work

Hi my names is pixeluted and i want print full table i using table.concat here is my script

local players = game.Players
local Survived = {}
local Died = {}
wait(3)
for y,player in pairs(players:GetChildren()) do
	table.insert(Survived,player)
	local PlayerCharacter = workspace:WaitForChild(player.Name)
	PlayerCharacter.Humanoid.Died:Connect(function()
		table.remove(Survived,y)
		table.insert(Died,player)
		print(table.concat(Survived,","))
		print(table.concat(Died,","))
	end)
end
while wait(5) do
	print(table.concat(Survived,","))
	print(table.concat(Died,","))
end

And this is error i have Screenshot by Lightshot
Thank for reading

I don’t get what you mean, are you trying to print a table? If so they you may want to use @Ozzypig’s Repr module.

2 Likes

You’re inserting player objects into your table. Change them to player names instead. That means: anywhere you have table.insert(x, player), add .Name to player.