Example5_7B - { public static void main(String args) throws...

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

View Full Document Right Arrow Icon
//******************************************************* // Program -- Checking Account Balance. // This program calculates a customer's checking account // balance at the end of the month. //******************************************************* / import java.io.*; import java.util.*; i public class Example5_7B
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: { public static void main(String args) throws IOException { int num; int sum = 0; Scanner inFile = new Scanner(new FileReader("numData.txt")); while (inFile.hasNext()) { num = inFile.nextInt(); sum = sum + num; }//end while System.out.println("Sum = " + sum); } }...
View Full Document

This note was uploaded on 06/17/2011 for the course COMP 2301 taught by Professor Staff during the Spring '10 term at Kennesaw.

Ask a homework question - tutors are online