Preventing nested code blocks [Tip/Trick]
Posted: 11 Mar 2010
Updated: 11 Mar 2010
Licence: The Code Project Open License (CPOL)
The easiest readable and maintainable code, is code that contains no nested blocks.Although sometimes unavoidable, preventing nested code blocks should be part of any coding guideline. Two basic rules:1) Exit First Rule2) DelegateRule 1 simply means that first any condition must be...