We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9bb97c0 commit dcb1fc5Copy full SHA for dcb1fc5
python/age.py
@@ -2,9 +2,5 @@
2
age = int(input("Enter Age : "))
3
4
# condition to check voting eligibility
5
-if age>=18:
6
- status="Eligible"
7
-else:
8
- status="Not Eligible"
9
-
10
-print("You are ",status," for Vote.")
+status="Eligible" if age>=18 else "Not Eligible"
+print(f"You are {status} for Vote.")
0 commit comments