In the Popular section choose: Java: A concurrent, class-based, statically typed object-oriented language.
Click the pencil icon next to your repl name.
In the Default name: input box type: InputOutput
Delete all the lines of code provided as an example.
Copy the InputOutput.java Template (Java) code (below)
Paste that code into your new InputOutput class in the editor
Change the @author put-your-lastname-here
Replace the blank on the Scanner
line with: Scanner(System.in)
After the // add a line here to output a message advising the user to enter 9999 to exit
comment line add: System.out.println( "Enter '9999' to exit" ); // informs user how to exit
Replace the blank after the if (num == 9999) {
line with: break;
Replace the blank on the if ()
line with: cnt > 0
Replace the blank on the ave =
line with: sum / (double) cnt;
Replace the blank after the } else {
line with: ave = 0;