How Big Should a Function Be? do Robert C. Martin (aka Uncle Bob) é um post deve ser impresso e sempre relembrado por sua equipe de desenvolvimento. Abaixo algumas frases do post (Não deixe de conferir a versão completa, leitura rápida em 2 minutos)
The body of a try block should also be a function call; and the word try should be the first word in the function.
A source file should read like a newspaper article. Newspaper articles begin with a headline, followed by a single synoptic paragraph, followed by paragraphs full of ever increasing detail. The ideal article can be read until it gets boring. A source file should read the same way.
Nested ifs and while’s should be avoided in most cases.