Assignemnt #23 and More User Input of Data
Code
/// Name: Mark Katz
/// Period: 6
/// Program Name: More User Input of Data
/// File Name: MoreInput.java
/// Date Finished: 9/15/15
import java.util.Scanner;
public class MoreInput
{
public static void main( String[] args )
{
String First, Last, Login;
int Grade, ID;
Double GPA;
Scanner keyboard = new Scanner(System.in);
System.out.println( "Please enter the following information so I can sell it for a profit!" );
System.out.println( "First Name: " );
First= keyboard.next();
System.out.println( "Last Name: " );
Last= keyboard.next();
System.out.println( "Grade (9-12): " );
Grade= keyboard.nextInt();
System.out.println( "Student ID: " );
ID= keyboard.nextInt();
System.out.println( "Login: " );
Login= keyboard.next();
System.out.println( "GPA (0.0-4.0) ");
GPA= keyboard.nextDouble();
System.out.println( "Your Information: ");
System.out.println( "Login: " + Login + "" );
System.out.println( "ID: " + ID + "" );
System.out.println( "Name: " + Last + "," + First + "" );
System.out.println( "GPA: " + GPA + "" );
System.out.println( "Grade: " + Grade + "" );
}
}
Picture of the output