#while
x = 1
while x < 5:
print(x)
x += 1
print("loop ended")
#continue while
x = 0
while x < 5:
x += 1
if x == 3:
continue
print(x)
#break while
x = 1
while x < 5:
if x == 3:
break
print(x)
x += 1
#else while
x = 1
while x < 5:
print(x)
x += 1
else:
print('While loop is a great tool')
#nested while
x = 1
while x < 10:
print(x)
while x < 3:
print("We are at the very beginning")
x += 1
else:
print('While loop is a great tool')