-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathExercise1.java
More file actions
31 lines (20 loc) · 879 Bytes
/
Copy pathExercise1.java
File metadata and controls
31 lines (20 loc) · 879 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
package Exercises;
// This is the template code.
public class Exercise1 {
public static void main(String args[]) {
String question = "";
String choiceOne = "";
String choiceTwo = "";
String choiceThree = "";
String correctAnswer = choiceTwo;
// Write a print statement asking the question
// Write a print statement giving the answer choices
// Have the user input an answer
// Retrieve the user's input
// If the user's input matches the correctAnswer...
// then the user is correct and we want to print out a congrats message to the user.
// If the user's input does not match the correctAnswer...
// then the user is incorrect and we want to print out a message saying that the user
// is incorrect as well as what the correct choice was.
}
}