Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Netbeans project named Lab5. Give the main class an appropriate name with the following assignment description in mind. A program that will ask the user

Netbeans project named Lab5. Give the main class an appropriate name with the following assignment description in mind.

A program that will ask the user to enter their name and to enter the number of steps they walked in a day. Then ask them if they want to continue. If the answer is "yes" ask them to enter another number of steps walked. Ask them again if they want to continue. If they put anything besides "yes" you should end the program by telling them "goodbye, [NAME]" and the sum of the number of steps that they have entered.

Example run below. Text from the program is in green. Responses from the user are in red. I am using different colors to show you what your program will print versus what a test user might type. Your output and input in NetBeans will NOT be in different colors.

Please enter your name:Dave

Please enter the number of steps you have walked:1000

Would you like to continue? (Type 'yes' if yes):yes

Please enter another number of steps:2000

Would you like to continue? (Type 'yes' if yes):yes

Please enter another number of steps:3000

Would you like to continue? (Type 'yes' if yes):no

Goodbye, Dave. The total of the number of steps you entered is 6000.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored 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

Recommended Textbook for

Modern Dental Assisting

Authors: Doni Bird, Debbie Robinson

13th Edition

978-0323624855, 0323624855

Students also viewed these Programming questions