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 of the following is not a concern regarding waste? Noise pollution Groundwater contamination Impact on wildlife habitat Gas saved by recycling paper
When the price of a product increases, consumers will often demand and purchase substitute goods that are cheaper. true false?
Why do most people live in the eastern part of the United States
Which point(s) would cause the set of points to no longer represent a function? (Select all that apply.) (1,1) (5,1) (-2,5) (0,2)
in a firework display, energy is released in___?
Which of the following statements is part of the theory? a. Only plants are composed of cells. b. All cells are produced from other cells. c. cells can
12) DNA and RNA differ in all BUT one of the following ways. A) DNA is double-stranded, while RNA is single stranded. B) RNA uses the sugar ribose in its b
where and how is the densest water in the oceans foundNear the poles as sea ice formsNear the equator due to heavy rain.Near the equator where rain is scarce
Factors of 32 and 50
During exercise your body releases heat by A)using stored energy B) increasing breathing C) decreasing heart rate D) deilating blood vessels