Answer :
num = int(input("Enter a number: "))
print(str(num)+" is even" if num % 2 == 0 else str(num)+" is odd")
I wrote my code in python 3.8. Best of luck.
num = int(input("Enter a number: "))
print(str(num)+" is even" if num % 2 == 0 else str(num)+" is odd")
I wrote my code in python 3.8. Best of luck.