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

A bucket is being filled at a rate of 5/6 gallon in 1/4 minute. What is the unit rate in gallons per minute?
How to write 3,801,440 in expanded form
the time, t(in minutes), you need to type a certain paper varies inversely with the rate, r(in words per minute), that you can type. when typing 40 words per mi
A straight road rises at an inclination of 0.3 radian from horizontal. Find the slope and change in elevation over a one mile section of the road.
The half life of protactinium 234 in its ground state is 6.69 h. What fraction of a given amount remains after 26.76 h
which valve prevents blood to flow from the right atrium to the right ventricle
Is this the correct procedure for this kind of question? Apparently the answer is supposed to be log6/log5.
Please need this question answered asap
choose the mathematical sentence that most accurately expresses the information in the problem, and would be most helpful in solving it. There are 24 tennis ba
Environmental influences begin at birth and continue throughout life. T F