Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

1. Ask user to input their name and age. 2. Displays a different message depending on the age given. Use if statements only. - age

1. Ask user to input their name and age. 2. Displays a different message depending on the age given. Use if statements only. - age is less than 16, say "You can't drive." - age is less than 18, say "You can't vote." - age is less than 25, say "You can't rent a car." - age is 25 or over, say "You can do anything that's legal."

image text in transcribed

Task 3: 1. Ask user to input their name and age. 2. Displays a different message depending on the age given. Use if statements only. age is less than 16, say "You can't drive." age is less than 18, say "You can't vote." age is less than 25, say "You can't rent a car." age is 25 or over, say "You can do anything that's legal." A person who is under 16 will display three messages, one for being under 16, one for also being under 18, and one for also being under 25

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access with AI-Powered Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions