Tip 3 | Design with Tests |
[ââBrown Belt] You may not start designing new code right up front, but you will soon enough. |
Where our previous tip, Tip 2, âInsist on Correctnessâ, focused on making sure your code does what itâs supposed to do, here we focus on the meta-question, âWhat should this code do?â
On the surface, it would seem puzzling that a programmer would write code without knowing, well ahead of time, what itâs supposed to do. Yet we do it all the time. Faced with a problem, we charge off writing code and figure things out as we go. Programming is a creative act, not a mechanical one, and this process is akin to a painter ...
Get New Programmer's Survival Manual now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.