Write a complete Java program that performs the following tasks: 1. Ask the user to enter the last two digits of his/her student ID. 2. Break the number into two digits using arithmetic operators, then store the first and second digits in integer variables named digit1 and digit2 3. Find and print the following: Note: ● • The product of digit1 and digit2. • The sum of digit1 and digit2 The average of digit1 and digit2 The maximum of the two numbers; digitl digit2 using a method from the class Math. The class name of your Java program must be your first name. Your answer should have the code as text as well as the screenshot of the program output (using your own student ID) as a part of your answer. Otherwise, name: Hanan Mohammed k Alghamdi ID: S210027561 Typical run of the ● 03.java Help program Compile Messages JGRASP Messages Run 1/0 Interactions End Clear ----GRASP exec: java Q3 Enter the last two numbers of your student ID: 46 The first digit 4, the second digit =6 Product: 46 = 24.0 10.0 sum: 4+6 average :5.0 maximum is 6 ----GRASP: operation complete.
Write a complete Java program that performs the following tasks: 1. Ask the user to enter the last two digits of his/her student ID. 2. Break the number into two digits using arithmetic operators, then store the first and second digits in integer variables named digit1 and digit2 3. Find and print the following: Note: ● • The product of digit1 and digit2. • The sum of digit1 and digit2 The average of digit1 and digit2 The maximum of the two numbers; digitl digit2 using a method from the class Math. The class name of your Java program must be your first name. Your answer should have the code as text as well as the screenshot of the program output (using your own student ID) as a part of your answer. Otherwise, name: Hanan Mohammed k Alghamdi ID: S210027561 Typical run of the ● 03.java Help program Compile Messages JGRASP Messages Run 1/0 Interactions End Clear ----GRASP exec: java Q3 Enter the last two numbers of your student ID: 46 The first digit 4, the second digit =6 Product: 46 = 24.0 10.0 sum: 4+6 average :5.0 maximum is 6 ----GRASP: operation complete.
Chapter6: Looping
Section: Chapter Questions
Problem 2PE
Related questions
Question
Please help me quickly and use my name and ID PLEASE HELP
![Write a complete Java program that performs the following tasks:
1. Ask the user to enter the last two digits of his/her student ID.
2. Break the number into two digits using arithmetic operators, then store the first and
second digits in integer variables named digit1 and digit2
3. Find and print the following:
Note:
The class name of your Java program must be your first name.
Your answer should have the code as text as well as the screenshot of the
program output (using your own student ID) as a part of your answer.
Otherwise,
name: Hanan Mohammed k Alghamdi
ID: S210027561
Typical run of the
Q3.java
The product of digit1 and digit2.
The sum of digit1 and digit2
The average of digit1 and digit2
The maximum of the two numbers; digitl digit2 using a method from the
class Math.
Clear
Compile Messages JGRASP Messages Run 1/0 Interactions
End
Help
program
►
----jGRASP exec: java Q3
Enter the last two numbers of your student ID:
46
The first digit 4, the second digit =6
Product: 46 = 24.0
sum: 4 + 6 = 10.0
average :5.0
maximum is 6
----GRASP: operation complete.](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2F17d1c9ea-31f6-46e6-8184-e1e8fbff5e32%2Fa32100e1-cc31-4ab3-bfb6-3801850a8eaf%2Fycsno9a_processed.jpeg&w=3840&q=75)
Transcribed Image Text:Write a complete Java program that performs the following tasks:
1. Ask the user to enter the last two digits of his/her student ID.
2. Break the number into two digits using arithmetic operators, then store the first and
second digits in integer variables named digit1 and digit2
3. Find and print the following:
Note:
The class name of your Java program must be your first name.
Your answer should have the code as text as well as the screenshot of the
program output (using your own student ID) as a part of your answer.
Otherwise,
name: Hanan Mohammed k Alghamdi
ID: S210027561
Typical run of the
Q3.java
The product of digit1 and digit2.
The sum of digit1 and digit2
The average of digit1 and digit2
The maximum of the two numbers; digitl digit2 using a method from the
class Math.
Clear
Compile Messages JGRASP Messages Run 1/0 Interactions
End
Help
program
►
----jGRASP exec: java Q3
Enter the last two numbers of your student ID:
46
The first digit 4, the second digit =6
Product: 46 = 24.0
sum: 4 + 6 = 10.0
average :5.0
maximum is 6
----GRASP: operation complete.
Expert Solution
![](/static/compass_v2/shared-icons/check-mark.png)
This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
Step by step
Solved in 3 steps with 1 images
![Blurred answer](/static/compass_v2/solution-images/blurred-answer.jpg)
Knowledge Booster
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.Recommended textbooks for you
![EBK JAVA PROGRAMMING](https://www.bartleby.com/isbn_cover_images/9781337671385/9781337671385_smallCoverImage.jpg)
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT
![Microsoft Visual C#](https://www.bartleby.com/isbn_cover_images/9781337102100/9781337102100_smallCoverImage.gif)
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage
![EBK JAVA PROGRAMMING](https://www.bartleby.com/isbn_cover_images/9781337671385/9781337671385_smallCoverImage.jpg)
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT
![Microsoft Visual C#](https://www.bartleby.com/isbn_cover_images/9781337102100/9781337102100_smallCoverImage.gif)
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage
![EBK JAVA PROGRAMMING](https://www.bartleby.com/isbn_cover_images/9781305480537/9781305480537_smallCoverImage.jpg)
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781305480537
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT
![C++ for Engineers and Scientists](https://www.bartleby.com/isbn_cover_images/9781133187844/9781133187844_smallCoverImage.gif)
C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr
![C++ Programming: From Problem Analysis to Program…](https://www.bartleby.com/isbn_cover_images/9781337102087/9781337102087_smallCoverImage.gif)
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning