import java.util.Scanner; /** * A program that shows reading in from the console and doing arithmetic. * @author sarasprenkle */ public class TestProgram { /** * @param args */ public static void main(String[] args) { System.out.println("Test Program for CISC370"); System.out.println("We'll do a little math...\n"); System.out.print("Please enter the width of a square: "); Scanner scan = new Scanner(System.in); int width = scan.nextInt(); System.out.print("Please enter the height of a square: "); int length = scan.nextInt(); System.out .println("The area of your square is " + length * width + "."); /* String niceGreeting = "Hello"; String firstName = "Clark"; String lastName = "Kent"; String blankSpace = " "; String greeting = niceGreeting + "," + blankSpace + firstName + blankSpace + lastName; System.out.println(greeting); */ } }