1日目段階9です
This commit is contained in:
@@ -5,8 +5,10 @@ public class Main {
|
||||
public static void main(String[] args) {
|
||||
// TODO 自動生成されたメソッド・スタブ
|
||||
|
||||
while (true) {
|
||||
|
||||
System.out.println("検索したい社員IDを入力してください(終了したい場合は0)");
|
||||
Scanner scanner = new Scanner(System.in);
|
||||
System.out.println("検索したい社員IDを入力してください");
|
||||
String id = scanner.nextLine();
|
||||
boolean bo = false;
|
||||
|
||||
@@ -40,9 +42,15 @@ public class Main {
|
||||
// employees[i].isMatchId("99999");
|
||||
continue;
|
||||
}
|
||||
if (bo == false) {
|
||||
if (bo == false && !id.equals("0")) {
|
||||
System.out.println("該当する社員が見つかりませんでした");
|
||||
}
|
||||
if (id.equals("0")) {
|
||||
System.out.println("システムを終了します");
|
||||
break;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user