Jaynerandolph1640 Jaynerandolph1640
  • 23-12-2021
  • Computers and Technology
contestada

Write a program to test if an integer input from the keyboard is odd or even. Sample Run 1: Enter a Number: 78 Even Sample Run 2: Enter a Number: 17 Odd

Respuesta :

6385726215
6385726215 6385726215
  • 24-12-2021

Answer:

number = int(input("Enter a number: "))

if number % 2 == 0:

   print("Even")

else:

   print("Odd")

Explanation:

Currently taking python at school. On the last few lessons.

Answer Link

Otras preguntas

On what interval is the functioning decreasing m(x)=4x^3-5x^2-7x?
The “physical and spiritual cost to the men and women and children” who were bearing the burden of America’s industrial achievements was featured in the inaugur
Facts about the declaratory act of 1766
What country controlled most of Poland in 1815?
What 1896 U.S. Supreme Court decision upheld the constitutionality of social segregation and advanced the "separate but equal" doctrine? Plessy v. Ferguson Marb
why do vegetable oils make good fuels
By the end of World War II, many Westerners believed that people had the right to self-determination and self-government. Many Western imperial nations no longe
Who did Caesar make queen of egypt?
what was a trench intended to accomplish on the battle lines between france and germany during the fighting in the great war
Which two European countries had established the most colonies in Africa by the end of the 1800s? A. Portugal and the Netherlands B. Britain and France C. Brita