CS 0401 Lecture Notes - Lecture 5: Javadoc
Document Summary
When want it to stop when: roll == 7 || roll == point while (! (roll == 7 || roll == point)) Or, we can apply de morgan"s laws ( x || y ) -> (!x && !y) ( x && y) -> (!x || !y) Breaks break works inside of the body of a loop while (condition){ if (condition2) break; if there was any code below in the loop body is going to be skipped also will break out of the loop. Break means something different during a loop (do-while, while, for) than it does during switch cases. Continue works similarly but not identically to break while (condition){ if (condition2) continue; continue takes us back to the beginning of the loop skips any of the information after continue and goes back. Unlike with break, loop may continue with continue. \" prints out " in general, don"t need to escape apostrophes inside of strings.