A program that accepts user input then determines whether they can drive or not
try:
age = int(input("Your age: "))
if age>18 and age<=100:
print("You can drive!")
elif age<18:
print("Sorry! You cannot drive!")
elif age==18:
print("Come on site and take the test.")
elif age>100 and age<200:
print("You are overage. Sorry!")
else:
print("Humans do not have this age size")
except:
print("Only numeric input acceptable")
Comments
Post a Comment
Write something to CodeWithAbdur!