Assignment #25 A Dumb Calculator
Code
///Name: Ian Grant
///Period:5
///Project Name: A Dumb Calculator
///File Name:DumbCalc.java
///10/14/15
import java.util.Scanner;
public class DumbCalc
{
public static void main(String[] args)
{
double first,second,third;
Scanner keyboard= new Scanner(System.in);
System.out.print("What is your first number? ");
first=keyboard.nextDouble();
System.out.print("What is your second number? ");
second=keyboard.nextDouble();
System.out.print("What is your third number? ");
third=keyboard.nextDouble();
System.out.println("("+first+"+"+second+"+"+third+") /2 is ..."+((first+second+third)/2));
}
}
Output