Skip to content

Commit ee1ee06

Browse files
committed
Added challange 4.4.6
1 parent de7c8e2 commit ee1ee06

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
"""
2+
This program made by Joe
3+
"""
4+
userage = bool(int(input("Age: ")) >= 35)
5+
user_birthplace = bool(input("Born in the US? (Yes/No): ") == "Yes")
6+
user_residency = bool(int(input("Years of Residency: ")) >= 14)
7+
8+
if (userage and user_birthplace) and user_residency:
9+
print("You are eligible to run for president.")
10+
else:
11+
print("You are not eligible to run for president.")
12+
13+
if userage != True:
14+
print("You are too young. You must be at least 35 years old.")
15+
if user_birthplace != True:
16+
print("You must be born in the U.S. to run for president.")
17+
print(user_residency)
18+
if user_residency != True:
19+
print("You have not been a resident for long enough.")

0 commit comments

Comments
 (0)