Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

How would I print only the 2nd comma of return?

I want to print something just like a table using indexes

function returnstuff()
	
	return 'G','A','Y'
end

print(returnstuff()[2])


--Since Arrays start at 1 this should print A

but I don't know how to do these stuff

1 answer

✓ Accepted answer
function returnstuff()

    return 'P','A','Y'
end
var1, var2, var3 = returnstuff()
print(var2)

This discussion is preserved as it was. New answers, comments, and votes are closed.