Logical optimizations

Logical optimizations

Articles

Nested if blocks can often be rewritten as a single conjunction, but only when each if fully owns the body with no else or trailing code.