Skip to content

Commit

Permalink
add : switch문
Browse files Browse the repository at this point in the history
  • Loading branch information
5w31892p committed Dec 24, 2022
1 parent b91a893 commit bf1b908
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions homework/Homework02.java
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,21 @@ public static void main(String[] args) {
System.out.println("1~4까지의 숫자만 입력해주세요.");
}
}
// while (true) {
// int answer = scanner.nextInt();
// switch (answer) {
// case 3:
// System.out.println("정답입니다.");
// break;
// case 1:
// case 2:
// case 4:
// System.out.println("오답입니다.\n다음 중 프로그래밍 언어가 아닌것은?");
// continue;
// default:
// System.out.println("올바른 숫자를 입력해주세요.\n다음 중 프로그래밍 언어가 아닌것은?");
// continue;
// }
// break;
}
}

0 comments on commit bf1b908

Please sign in to comment.