Let me introduce you to The Magic Number Seven, Plus or Minus Two [0]. This is the amount of state your monkey brain can hold in working memory.
This number is why nesting code is almost always heinous. Once the number of nested conditionals exceeds working memory, your monkey brain cannot hold the state and drops all the variables.
Deeply nested statements is my number one code smell, and can almost always be easily refactored.
This number is why nesting code is almost always heinous. Once the number of nested conditionals exceeds working memory, your monkey brain cannot hold the state and drops all the variables.
Deeply nested statements is my number one code smell, and can almost always be easily refactored.
[0] https://en.wikipedia.org/wiki/The_Magical_Number_Seven,_Plus...