Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //THIS IS HOW I STARTED
- import java.util.Scanner;
- public class TestAverage
- {
- public static void main(String[] args)
- {
- double test1;
- double test2;
- System.out.println("Enter test:");
- }
- }
- //THIS IS THE QUESTION!!
- //1. Create a program that will have a project and class
- //called TestAverage. It will have 2 double variables declared as test1 and test2.
- //It will prompt the user to enter in the 2 values for the test1 and test2 as doubles.
- //It will output to the console if the 2 tests entered were 100.0 and 96.0
- //Test1 100.0
- //Test2 96.0
- //Sum 196.0
- //Avg 98.0
- //Max 100.0
- //Min 96.0
- //HINT You must use the Math.min and Math.max methods to display the max
- //and min of the 2 tests entered.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement