Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

For i,v in pairs error?

Asked by
Vividex 162
10 years ago

Just playing around with for i,v in pairs since its not the best thing I understand, why doesnt this print all the words in the table?

table = {
    "Me", "Me2", "AndMe"
}

for i,v in pairs (table()) do
    print(i,v)
    wait()
end

1 answer

Log in to vote
4
Answered by 10 years ago

Remove your parenthesis for table in pairs()

for i,v in pairs (table) do
0
Thanks :3 Vividex 162 — 10y
0
I feel so dumb qq Vividex 162 — 10y
Ad

Answer this question