menu
QAmmunity.org
Login
Register
My account
Edit my Profile
Private messages
My favorites
Register
Ask a Question
Questions
Unanswered
Tags
Categories
Ask a Question
write a program that asks the user to enter the persons age program should display whether the user is an infant or adult
asked
Feb 8, 2024
221k
views
5
votes
write a program that asks the user to enter the persons age program should display whether the user is an infant or adult
Engineering
college
BStruthers
asked
by
BStruthers
7.9k
points
answer
comment
share this
share
0 Comments
Please
log in
or
register
to add a comment.
Please
log in
or
register
to answer this question.
1
Answer
3
votes
# Get user input for age
age = int(input("Enter the person's age: "))
# Check if the person is an infant or an adult
if age < 1:
print("The person is an infant.")
elif age >= 1:
print("The person is an adult.")
else:
print("Invalid age input.")
Janjonas
answered
Feb 14, 2024
by
Janjonas
8.6k
points
ask related question
comment
share this
0 Comments
Please
log in
or
register
to add a comment.
Ask a Question
Welcome to QAmmunity.org, where you can ask questions and receive answers from other members of our community.
9.5m
questions
12.2m
answers
Other Questions
A water towers lowest point is 405 ft and the main line is 6 feet below the ground. The ground elevation is at 276 ft. The main line travels 2.9 miles. The pipe will travel through the following flanged
The bulk modulus of a fluid if it undergoes a 1% change in volume when subjected to a pressure change of 10,000 psi is (a) 0.01 psi (b) 0.001 psi (c) 0.00001 psi (d) 0.000001 psi (e) none of these
A car has an initial speed of 10 m/s. It then undergoes a constant acceleration of 0.05 m/s^2 over a distance of 5 km. Determine: a) The car final speed. b) The time needed to travel the 5 km.
Teresa is emotionally volatile, particularly with friends and boyfriends. She is extremely dramatic about even the smallest disappointments and is sexually and behaviorally very impulsive. Teresa would
Vitrification is a process of: a. Chemical reaction bonding of aggregate ceramic powder b. Cementing aggregate ceramic powder with a liquefied material c. Solid-state diffusion of aggregate ceramic powder
Twitter
WhatsApp
Facebook
Reddit
LinkedIn
Email
Link Copied!
Copy
Search QAmmunity.org