while loop odd numbers python

Solutions on MaxInterview for while loop odd numbers python by the best coders in the world

showing results for - "while loop odd numbers python"
Simon
08 Jun 2020
1# Python Program to Print Odd Numbers from 1 to N
2
3maximum = int(input(" Please Enter the Maximum Value : "))
4
5number = 1
6
7while number <= maximum:
8    if(number % 2 != 0):
9        print("{0}".format(number))
10    number = number + 1