what can we do with loops in python code example
Example 1: loops in python
#While Loop:
while ("condition that if true the loop continues"):
#Do whatever you want here
else: #If the while loop reaches the end do the things inside here
#Do whatever you want here
#For Loop:
for x in range("how many times you want to run"):
#Do whatever you want here
Example 2: python for loop
//x starts at 1 and goes up to 5 increasing by 2
for x in range(1,5,2):
print(x)