A loop repeats a block of instructions. for goes through the elements of a sequence or a range, while repeats as long as a condition remains true. break interrupts the loop and continue moves on to the next iteration. A while condition that never becomes false produces an infinite loop.
Example
for i in range(3):
print(i)