mirror of
https://github.com/System-End/APCSA.git
synced 2026-04-19 21:05:16 +00:00
lesson 1 done yay
This commit is contained in:
parent
c17245e959
commit
6dfe1096d8
2 changed files with 5 additions and 5 deletions
|
|
@ -5,13 +5,13 @@ import java.util.Scanner;
|
|||
public class U2_L1_Activity_One {
|
||||
|
||||
public static void main(String[] args) {
|
||||
Scanner scanner = new Scanner(System.in);
|
||||
Scanner scan = new Scanner(System.in);
|
||||
|
||||
System.out.println("What is your name?");
|
||||
String name = scanner.nextLine();
|
||||
String name = scan.nextLine();
|
||||
|
||||
System.out.println("What is your favorite number?");
|
||||
int favoriteNumber = scanner.nextInt();
|
||||
int favoriteNumber = scan.nextInt();
|
||||
|
||||
System.out.println(
|
||||
"Your name is " +
|
||||
|
|
|
|||
|
|
@ -9,11 +9,11 @@ public class U2_L1_Activity_Two {
|
|||
|
||||
System.out.println("The current order is " + order);
|
||||
|
||||
Scanner scanner = new Scanner(System.in);
|
||||
Scanner scan = new Scanner(System.in);
|
||||
System.out.println(
|
||||
"I want to eat something else, what do you want to eat?"
|
||||
);
|
||||
order = scanner.nextLine();
|
||||
order = scan.nextLine();
|
||||
|
||||
System.out.println("The order has changed to " + order);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue