Answers for "nested if else statement python"

1

how to use nested if else in python

Your_hight = int(input("What is Your hight:- "))
if Your_hight >= 120:
    print("You are good to go to the roller coster")
    your_age = int(input("What is your Age:- "))
    if your_age > 8:
        print("This is your ticket and have your seat on the roller coster")
    else:
        print("Sorry you can't go to the roler coster")
Posted by: Guest on August-09-2021
2

nested if statements python

if expression1:
   statement(s)
   if expression2:
      statement(s)
   elif expression3:
      statement(s)
   elif expression4:
      statement(s)
   else:
      statement(s)
else:
   statement(s)
Posted by: Guest on April-14-2021
-1

if then else python

a = 200
b = 33
if b > a:
	print("b is greater than a")

elif a == b:
	print("a and b are equal")

else:
	print("a is greater than b")
Posted by: Guest on August-21-2020

Code answers related to "nested if else statement python"

Python Answers by Framework

Browse Popular Code Answers by Language