Even or Odd
Completed
Read an integer and print even or odd.
Input
One integer.
Output
even or odd
Example
Input
4
Output
even
Editor
Python
Hints
A number is even when n % 2 == 0.
Use == to compare, = to assign.
Solution explanation
The if block runs when the condition is true, otherwise the else block runs.
Show solution
n = int(input())
if n % 2 == 0:
print("even")
else:
print("odd")