studentTests - { int average = 0; while(average<=4) {

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
import java.util.*; public class studentTests { static Scanner console = new Scanner(System.in); public static void main(String[]args) { String name; int test = 0; System.out.println("Enter Your Name"); name = console. next(); System.out.println("The student's name is " + name); calculatedAverage(test); System.out.println("The grade for the class is = " + calculatedGrade(average)); } public static void calculatedAverage(int t1)
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: { int average = 0; while(average<=4) { System.out.println("Enter a number that ranges from 0-100 separated by lines"); average = average + 1; t1 = console.nextInt(); int average2 = t1/5 + t1/5 + t1/5 + t1/5 +t1/5; } private static int calculatedGrade(int s) { average = calculatedAverage(test); return average; }}}...
View Full Document

This note was uploaded on 10/04/2010 for the course COMPUTER S 106 taught by Professor Moore during the Spring '08 term at Clark Atlanta.

Ask a homework question - tutors are online