ITEC 120 LAB 5 Back to Lab index page

This lab is made up of 2 completely different parts. First, you will electronically submit a file the same way you will submit your lab quiz Fri. Then, you'll write a program for lab5.

PART 1 - Submit a file electronically - Do this in the first 30 minutes of the lab!!!

In order to turn in lab quizzes and programming assignments, you'll put the necessary files in a folder on neelix. Turn in any java file so we can make sure the submission process works for you before you have to turn in your lab quiz (Fri, Sept 9).

Part 2 - Amazing grade averager

You will write Java program that will average 3 grades input by the user.

First, your program will ask the user to input what kind of assignment they will be entering grades for. (for example, they might enter test or report or project or quiz). Read this information as a String.

Your program will then prompt the user for 3 of those grades. Read the grades as integers.

Next, your program will average the three grades together, and output that number to one decimal place. (Use the DecimalFormat class to achieve this.)

Sample run:
Program outputs:

Welcome to the amazing grade averager.
Please enter the type of the assignment

User inputs: test
Program outputs: Please enter your score for test number 1:
User inputs: 77
Program outputs: Please enter your score for test number 2:
User inputs: 89
Program outputs: Please enter your score for test number 3:
User inputs: 94
Program outputs:


The average of your 3 test grades is 86.7

Once you have your program working, show your lab to the Peer Instructor to be checked off. You'll run your program a couple times for the Peer Instructor.