I used to always get confused whether I should use break, or continue. This is what helps me remember:
When to use break vs continue?
- Break - it's like breaking up. It's sad, you guys are parting. The loop is exited.
- Continue - means that you're gonna give today a rest and sort it all out tomorrow (i.e. skip the current iteration)!