Age Program in the python

technical talkiess
0

 var1 = 3

var2 = 5
var3 = 45

# if var2 > var3:
#     print("Greater")
# elif var2==var3:
#     print("Equal")
# else:
#     print("Leaser")

# user input ko check karna using if condition

# var6 = 23
# var5 =int(input())
# if var6 > var5:
#     print("Greater")
# elif var6==var5:
#     print("Equal")
# else:
#     print("Leaser")

#List me koi value hai ya nahi wo check karana using python

list_i = [1,2,3,4,5]

if 5 in list_i:
    print("Exists")


# agar hame check karna hai ki exists nahi hai to
if 10 not  in list_i:
    print("Not Exists")


# Program for user age calculation

var23 = 18

print("Enter Your Age")

var24 = int(input())
if (var24 < 7) or (var24 > 100):
    print("Please Enter the valid age")
elif var24 > var23:
    print("Allow to drive")
elif var24 == var23:
    print("Please come to office we will decide after discussion")
else:
    print("Not Allow to drive")
Tags

Post a Comment

0Comments

Thanks you for commenting your questions. I will see question and respond you.

Post a Comment (0)