The <variable> is a loop variable that is used to iterate over the <sequence>. The <sequence> can be a list, a string, a range, or any other iterable object. The <block of code> is the code that will be executed for each iteration of the loop.
The difference between for loop and while loop is that for allows initialization, condition checking and iteration statements on the top of the loop, whereas while only allows initialization and condition checking at the top of the loop.
Answers & Comments
Answer:
The <variable> is a loop variable that is used to iterate over the <sequence>. The <sequence> can be a list, a string, a range, or any other iterable object. The <block of code> is the code that will be executed for each iteration of the loop.
Verified answer
Answer:
The difference between for loop and while loop is that for allows initialization, condition checking and iteration statements on the top of the loop, whereas while only allows initialization and condition checking at the top of the loop.
chill bro.....