1️⃣
for (String 2️⃣ : passwords) {
System.out.println(currPassword);
}What needs to go into 1️⃣ and 2️⃣for this code to compile?
String result = "";
for (String currLetter : letters) {
result += currLetter;
}
System.out.println(result);Assume the ArrayList<String> letters contains these strings:
| "1" | "2" | "3" |
|---|
What will appear in the console when the code is run?
Scanner numScanner = new Scanner("124 200");
int num = numScanner.nextInt();
while (num % 100 != 0) {
System.out.println("ping!");
}
System.out.println("Done!");What is displayed when this code runs?