I don’t usually have a tough time with motivation when it comes to programming. I am usually in a fit to get at it. However like most people, I will often come to a bit of code that I don’t want to write. It’s not because I think it will be hard, it usually means I have to load a big portion of the program into my head and sort out the details of how this new bit of code will affect the whole.
This is, of course, impossible to do in any program that is larger than a few hundred lines. So naturally I get some sensory overload, and it causes my mind to wander (which probably has a name that I should remember from college). This is when I will devour news…but that is a temporary fix, and at some point I know I’ll have to do this thing.
I wish I had some sort of trick I could play on myself that would stop me from putting off getting to work. I don’t. At some point, I just start typing and breaking things and fixing things and getting it done, but it feels wrong at first, like forcing yourself to put your hand on a hot stove. Your mind resists, but you do it anyway.
How do you deal with this?