Using the Problem to Solve the Problem
Programmers have a technique called TDD - Test Driven Development. The idea is to start from the end: before writing the code, you write a test that defines what the code should do. That test fails - obviously, the code doesn’t exist yet. Then you write the minimum code to make the test pass. Done, next test.
I use this every day at work. But I only recently realized I use the same thing for almost everything.
Marcos V. Pagelkopf Jr