I'd imagine that your tutor wanted that you use the break condition in the condition part of the for loop. You need to declare this condition before the loop and change it inside the loop.
boolean stop = false;
for (...; ... && !stop; ...) {
...
if (...) {
stop = true;
}
}