I've always (jokingly!) liked the amended 'adage'......
"If first you don't succeed... Then remove all evidence that you tried!!"
When 'programming' though, I always use the 'Top-Down' approach, to keep interest/feedback.
What I mean, is that most of my 'coding' is greatly associated with a Graphical / I/O interfaces
.
So if I KNOW that what I write will work, (eventually!), then I start with the graphics & visual layout.
I get self-gratifying 'feedback', by constantly referencing a 'working' result, & giving me new ideas.
Then, in vastly simplified 'blocks', I create a (obviously) 'WorkFlow' diagram, breaking it down to very
simplified blocks of code, handling even 'dummy' I/O calls, to test the 'Output'.... "Yea... looks good!".
And only getting into the REAL, 'heavy' SubRoutines/Blocks of real 'coding' in the final stages !!
Otherwise, I get bogged down with the technical semantics, which while 'important', leaves too big
a gap to any sort of visual/mental reward!!! Like someone working on a production line making some
little parts, and not seeing the end manufactured Machine, in use, and feeling important !!
So my 'coding' ALWAYS works, with results, at any stage. It just gets 'better'