I am trying to execute this program and cannot figure out what I am doing wrong.
ID: 3563037 • Letter: I
Question
I am trying to execute this program and cannot figure out what I am doing wrong. This is the first time I have used Python so I'm sure someone more advanced will find the error immediately.
#file: vote.py
#Name: Tiffany Ciesielski
#Start date: 9/23/2014
#purpose: Determing the age required to vote
print ("Voting Age Calculator")
age=input ("Enter your age")
if age <= 18:
print("You can vote")
elif age in range(1,17):
print ("You cannot vote")
elif age <64:
print ("You're a Senior Citizen...you deserve two votes!")
endofprogram =input("Please hit enter to exit from this program:")
Explanation / Answer
#file: vote.py
#Name: Tiffany Ciesielski
#Start date: 9/23/2014
#purpose: Determing the age required to vote
print ("Voting Age Calculator")
age=int(input ("Enter your age"))
if age >= 18 and age<64 :
print ("You can vote")
elif age in range(1,17):
print ("You cannot vote")
elif age >=64:
print ("You're a Senior Citizen...you deserve two votes!")
endofprogram =input("Please hit enter to exit from this program:")
Please Check this. Working on Python 3.3 version. If any error then tell me
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.