Asks the user to enter the name of your department using Scanner and asks you to enter three numbers of the type double named x, y, and z, use Scanner. The program should find the smallest number and use it to calculate the following expression: smallest? + 3 x9 expr 2 +1 * (smallest - 2) 2

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter2: Using Data
Section: Chapter Questions
Problem 14PE
icon
Related questions
Question
2. Write a Java program that do the Following:
Asks the user to enter the name of your department using Scanner
and asks you to enter three numbers of the type double named x, y, and z, use Scanner.
The program should find the smallest number and use it to calculate the following
expression:
smallest? + 3 x 9
2+1 * (smallest - 2) 2
expr =
Use print statement to print the department name, the smallest number, and the result
of the expression. Each in a separate line.
Transcribed Image Text:2. Write a Java program that do the Following: Asks the user to enter the name of your department using Scanner and asks you to enter three numbers of the type double named x, y, and z, use Scanner. The program should find the smallest number and use it to calculate the following expression: smallest? + 3 x 9 2+1 * (smallest - 2) 2 expr = Use print statement to print the department name, the smallest number, and the result of the expression. Each in a separate line.
Expert Solution
steps

Step by step

Solved in 3 steps with 2 images

Blurred answer
Knowledge Booster
Linux
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT