I want to do a switch in while loop where at the break of every switch statement the while loop stops and ask for an input like F, R, C, Q. The statement below works but the
Use a label on the loop:
loop: while (goodTotal > 0 && monTotal > 0) { // ... switch (input) { case 'f': // ... break loop; case 'r': // ... break loop; // ... } // ... }