The Rules of Code

What lies beneath

A single file should contain fewer than 20000 lines of code. Preferably 1000. A single file should contain only one class. If this breaks the previous rule then your class is probably too large: refactor. It would be nice if a single routine could fit into 100 lines of code. Unit testing is awesome and will almost certainly catch on. Use consistent formatting. Even better: don’t bother and let clang-format do it. [Read More]