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 variable-ratio schedule reinforces behavior after a:
Hey please please please please help I’ve been having trouble all day please help
Shakespeare gave most of his tragic heroes an impressive dying speech in which they say something significant about their own life and death. although he did no
A right rectangular prism is 514 in. wide, 1212 in. long, and 4 in. tall. What is the volume of the prism? a) 50  in3 b) 65 5/8  in3 c) 260  in3 d) 262 1/2  in
can someone help me in history ?
How is dna able to store genetic information using sequences?
Tommy is planning his science fair project. He wants to measure the rate of photosynthesis in plants that live in fresh water. Is this an example of a scientifi
I need help please help please please please
A cruise ship travels 1900 miles per trip. There are a total of 4 stops the ship makes, and the distance to the first stop is 460 miles. If the variable d stand
The fourth part of the declaration of independence states that the 13 colonies are