Assignemnt #124 and sum
Code
///Name: Luke Shin
///Period: 7
///Project Name: sum
///File Name: sum.java
///Date: 04/01/2016
import java.util.Scanner;
import java.io.File;
public class sum{
public static void main(String[] args) throws Exception{
int a,b,c;
System.out.print("Loading data....");
Scanner fileIn = new Scanner(new File("3nums.txt"));
a = fileIn.nextInt();
b = fileIn.nextInt();
c = fileIn.nextInt();
fileIn.close();
System.out.println("Done");
System.out.println(a+"+"+b+"+"+c+"="+(a+b+c));
}
}
Picture of the output