honryyy honryyy
  • 01-01-2021
  • Computers and Technology
contestada

Write a program that reads an integer and determines and prints whether it is odd or even.

Respuesta :

Cytokine
Cytokine Cytokine
  • 01-01-2021

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.

Answer Link

Otras preguntas

Which is better salary offer$550per 40-hour week or $13.00 per hour for 40 hours
How did Benjamin Banneker uses Rhetorical strategies to argue against slavery?Be specific Thank you,
what does 10a-a-a-a equal
500 reduced by 4 times my age is 232 .
First, think about what you would like to be doing twenty years hence. Then, find out what education you must have to achieve this goal.a.Fragmentb.Run-onc.Corr
Tell whether the set is closed under the operation indicated.If not closed, provide a counterexample.1.) integers under addition                            2.)
the region of flat land down by the ocean
A professional baseball team won 84 games this season.  The team won 14 more games than it lost.  There were no ties.  How many games did the team lose?  How ma
a jar contains 133 pennies. a bigger jar contains 1 2/7 times as many pennies. what is the value of the pennies in the bigger jar?
Choose the correct function/equation for the following description. A linear function whose graph has y-intercept 6.