1# Python program to check if the input number is odd or even.
2# A number is even if division by 2 gives a remainder of 0.
3# If the remainder is 1, it is an odd number.
4
5num = int(input("Enter a number: "))
6if (num % 2) == 0:
7 print("{0} is Even".format(num))
8else:
9 print("{0} is Odd".format(num))
1num = int(input("Enter a number: "))
2if (num % 2) == 0:
3 print("{0} is Even number".format(num))
4else:
5 print("{0} is Odd number".format(num))
1n = int(input("Enter a number: "))
2print(n,"is Even.") if (n % 2) == 0 else print(n,"is Odd.")
1injd = int(input('Enter a number'))
2n = injd % 2
3if n > 0:
4 print('This is an odd number')
5else:
6 print('This is an even number')