Driving eligibility teller program made with python.

 A program which tells that you are eligible to drive or not. 

print("Enter your age")
age=int(input())

if age>18:
print("tussi to pakka gaddi chala loge")
if age<18:
print("na beta tumse drive na ho paega")
if age==18:
print("beta pahaili fursat me apna lisence banvale ")
#upper one code is normal but next one is advance in which someone tell his/her age like impossible
then our program will not be confused..
#advance driving age checker
print("enter your age")
age=int(input())
if age<=12 and age>=1:
print("you should not even think about driving")
elif age>12 and age<18:
print("you can't drive")
elif age==18:
print("Go and get a driving license first")
elif age>18 and age<60:
print("Absolutely you can drive")
else:
print("You are joking")

I have made these by using If , Else and Elif functions.. these functions are amazing..

Comments

Popular posts from this blog

Single Inheritance, multiple inheritance and multilevel inheritance in python.

Git Commands.

Using class objects, Instance variables, and class variables, class methods and static method in python