What is the purpose of this code segment?
boolean found = false;
int i = 0;
while (!found && i < numbers.length) {
if (numbers[i] == 15) {
found = true;
} else {
i++;
}
}
What is the purpose of this code segment?
boolean found = false;
int i = 0;
while (!found && i < numbers.length) {
if (numbers[i] == 15) {
found = true;
} else {
i++;
}
}