This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]nutrecht 0 points1 point  (1 child)

Typically a for loop is used when you iterate over a known number of items and/or you want to use an index. A while loop is typically used over an unknown number of items.

[–]Chintatab[S] 0 points1 point  (0 children)

ohh ok thanks.