Assignemnt #22
Code
///Colin Hinton
///5th Period
///NAS
///NAS.java
///9/17/2015
import java.util.Scanner;
class NAS
{
public static void main(String [] args )
{
String name;
double sal;
int age;
Scanner keyboard = new Scanner(System.in);
System.out.println(" Hello. What is your name? ");
name = keyboard.next();
System.out.println(" Hi " + name + "! How old are you?");
age = keyboard.nextInt();
System.out.println(" So you are " + age + "? Thats old.");
System.out.print(" How much do you make, " + name + "?");
sal = keyboard.nextDouble();
System.out.println( sal + " I hope that's from a part-time job. Lel.");
}
}
Picture of the output