Which is better?

Which is Better?

while task.wait(1) do
end

or

while true do
    task.wait(1)
end
1 Like

(post deleted by author)

1 Like

Long story short, and without ChatGPT (Looking at you, @xavocs), there really is no difference whatsoever, besides a millisecond.

1 Like

The first loop takes 1 second to start and the second one is instant.

3 Likes

Stop using Chat-GPT to generate answers!
task.wait() returns elapsed time (a number), not a boolean. See task.wait reference.

1 Like

Love this website. Totally gibberish AI generated post can’t get removed.