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

How Do I make it so that this skips 2 times?

So What Im trying to do is Im trying to make it skip every 1 line so basically in the table it would go from "Hello" which is 1 and "To" and then it would finally go to "Helpers" is there any way I can do that?

local aTable = {"Hello","Welcome","To","Scripting","Helpers!"}

for i = 0, #aTable do 
    print(aTable[i]) print(aTable[2]) 
end

1 answer

✓ Accepted answer

u mean something like this?

local aTable = {"Hello","Welcome","To","Scripting","Helpers!"}
 
for i = 0, #aTable do
	if  aTable ~= "Welcome" or "Scripting" then -- if value is different then value then do
	    print(aTable[i]) print(aTable[2])
	end -- end the if
end

local aTable = {"Hello","Welcome","To","Scripting","Helpers!"}
 
for i = 0, #aTable do
	if  #aTable == 1 or 3 or 5 then -- if value is the same then value then do
	    print(aTable[i]) print(aTable[2])
	end -- end the if
end

~= means different then == means equal

means bigger then < means smaller then = means bigger or same <= means smaller or same

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