(python )Write a program to accept the name and age of a
person and print "eligible to vote" if over 18.
Answers
Answered by
3
Answer:
# input age
age = int(input("Enter Age : "))
# condition to check voting eligibility
if age>=18:
status="Eligible"
else:
status="Not Eligible"
print("You are ",status," for Vote.")
Answered by
0
Answer:
name = input("Enter your name: ")
age = int(input("Enter your age: "))
if age >= 18:
print(name+ " is eligible to vote")
else:
print(name+ " is not eligible to vote")
Similar questions