I have started learning Python and try to use the while loop in an if-else statement but is not executing as it’s supposed to be. Can you explain me why
this the code
a = int(input("enter number: "))
if(a<21):
while (a>=20):
print(a)
a = a + 1
else:
print("your numer should be less then 20")
I was expecting to print numbers till the 20th number
New contributor
1