Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a Java program that computes the sum and the average of any three decimal numbers provided by the user. The program asks the user

Write a Java program that computes the sum and the average of any three decimal numbers provided by the user.

The program asks the user to input three decimal numbers one at a time. It will compute the sum and the average of the three numbers. Then it will display the three numbers, their sum and the average in a single output dialog box. See Test section below.

-----------------------------------------

Test Run

Enter the first number:

2.5

Enter the second number:

3.3

Enter the third number:

4.4

The sum of 2.5, 3.3 and 4.4 is 10.2

The average of 2.5, 3.3 and 4.4 is 3.4

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_2

Step: 3

blur-text-image_3

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

Big Data, Mining, And Analytics Components Of Strategic Decision Making

Authors: Stephan Kudyba

1st Edition

1466568704, 9781466568709

More Books

Students also viewed these Databases questions

Question

4. It is a social energy that moves organization members to act.

Answered: 1 week ago

Question

Why is the System Build Process an iterative process?

Answered: 1 week ago