Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

I need to a program in java that will find the average age of a group of students. The first question the program should ask

I need to a program in java that will find the average age of a group of students. The first question the program should ask the user is how many students are there in the class? The user should then be prompted to enter the ages one at a time, and the program should display the average age at the end. But, if the age is entered less than 0 by mistake, the program should show an error message and let the user enter this age again. The program should be able to detect a situation that the user entered is not a number.

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

Question

Explain all drawbacks of the application procedure.

Answered: 1 week ago

Question

Determine Leading or Lagging Power Factor in Python.

Answered: 1 week ago