C.10. Program Flow

C.10.1. Loops

Do not use continue statements without good reason in large blocks of code as they can make it difficult to follow.

C.10.2. goto

Do not use goto, or indeed functions for non-local jumps, unless there is really no alternative. They make code very difficult to follow.

C.10.3. switch Statements

Consider using switch statements to improve the readability of code where you have excessively long chains of if else statements. Where the same switch statement is duplicated throughout the code, however, this will be difficult to maintain. Consider changing your code (probably the data model) so that the switch is not needed.