sarahalbaloushi sarahalbaloushi
  • 16-08-2021
  • Computers and Technology
contestada

write a program to check whether the number is odd or even using 'if' statement in python

Respuesta :

belongtoinsarifamily
belongtoinsarifamily belongtoinsarifamily
  • 16-08-2021

Answer:

Python Program to Check if a Number is Odd or Even :

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

if (num % 2) == 0:

print("{0} is Even number". format(num))

else:

print("{0} is Odd number". format(num))

Answer Link

Otras preguntas

why do animals that live in the Artic ocean have so much blubber
few things could survive without the presence of what the gas that absorbs ultraviolet radiation
how can we change a fraction into a decimal? PLEASE HELP ME!
The least common multiple of 2 and 4
what percent of 371 is 120?
You need to cover the playground of a child development center with mulch. The playground is 125 feet long and 60 feet wide. You want the mulch to be at least 6
H(n)= -2n+4; find h(4)
What is the final step in the cinnamon-coconut biscuits recipe? Mix the flours and corn meal. Add the coconut spread to the dough. Shape the dough into waln
When did the berlin wall fall?
If land was cleared 100 years ago for farming and has recently returned to its natural state, covered with plants and trees, identify the activity that took pla