Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a complete program named Compute WeightedSum.java. The program reads two integer numbers from console and displays the weighted average of these two numbers. (refer

image text in transcribed
Write a complete program named Compute WeightedSum.java. The program reads two integer numbers from console and displays the weighted average of these two numbers. (refer to example code "ComputeArea With ConsoleInput.java" posted on Moodle) // Define class name as: // Main method header //Create a new object input l/Prompt user to enter an integer number 1 // Declare an integer variables x, and assign a value by invoking nextInt() to call the object input 09 // Prompt user to enter an integer number2 // Declare an integer variable y and assign the input integer number by invoking nextinto using / the calling object input //display the weighted sum of number and number2: 3*number1 + 2number2

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

More Books

Students also viewed these Databases questions

Question

2. Place a value on the outcomes.

Answered: 1 week ago