
Build and test the idea in your head before you build it for real
From My Inventions by Nikola Tesla · Part I. My Early Life
Tesla's working method was to resist rushing to the workshop. When an idea came, he built it up in his imagination, changed the construction, made improvements and even ran the machine in his mind, noting if it was out of balance. Only when he could see no fault anywhere did he make the real thing. He claimed his devices then worked as planned.
Few of us can picture a turbine in full detail, but the habit scales down. Walk through a plan, a talk or a piece of code in your head first, step by step, and ask where it breaks. Problems found in thought are the cheapest ones to fix.
When I get an idea I start at once building it up in my imagination. I change the construction, make improvements and operate the device in my mind.
Apply it
Before starting your next project, spend ten quiet minutes running it in your mind from start to finish. Write down every point where it could fail.