Jul 14
Here is the simple example of for loop in python Code: //This line is important,This is where you declare how many times the loop should be executed in range,To execute the loop ten times you declare range(1,10):
for x in range(1,10):
print x Output: In the above loop x is the variable… and then range can be replaced by array so you do want to specify the length of the array when you are going to use array values in the for loop 123456789