Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

Is it possible for a programmer to suffer the equivalent of writer's block? What strategies are there to overcome it?

share|improve this question

closed as too broad by gnat, MichaelT, GlenH7, jwenting, Bart van Ingen Schenau May 31 at 9:02

There are either too many possible answers, or good answers would be too long for this format. Please add details to narrow the answer set or to isolate an issue that can be answered in a few paragraphs.If this question can be reworded to fit the rules in the help center, please edit the question.

13  
Yeah there exists one. Generally goes off the minute my manager files his leave application. –  Fanatic23 Jan 8 '11 at 8:42
    
@Fanatic23: +Lots for that, but +1 will have to do. –  Andy Jan 8 '11 at 10:41
    
I dont really understand this comment. Do you mean if your manager is on holiday you find it difficult to motivate yourself? –  codecowboy Jan 8 '11 at 10:42
    
No. I mean it's easier to get on with stuff without the manager tryng to 'manage' every single aspect of what I am doing without knowing exactly what he is talking about. It was just a facetious comment. –  Andy Jan 8 '11 at 10:46
    
I had a similar experience Analysis to Paralysis –  Cape Cod Gunny Oct 7 '13 at 17:47

5 Answers 5

Funny you ask. I was just talking with one of my engineers today about programmer's block.

I recommend programmers have 2 or 3 active tasks going at a time that he/she can work on. When you get stuck somewhere, it's nice to be able to switch gears and work on something else for awhile and then come back to the problem with a fresh perspective.

I find that when I come back to the problem, I oftentimes come up with a solution/plan that I might not have otherwise come up with. Sometimes when working on one task, I run into something there that actually triggers the light bulb in my head for the problem that I was struggling with.

One of the other engineers I work with says he'll take a 10 minute break and go take a walk. He says that when he comes back to his desk, the answers suddenly start pouring back in.

I find it helpful to talk through the problem with someone else, even if that someone else isn't a programmer. I can't count the number of times I've been just talking about a problem when suddenly the answer comes to me.

In short, I think the best advice is that if you're stuck, switch gears for a bit.

share|improve this answer
3  
This is great advice - thanks. –  codecowboy Jan 8 '11 at 10:44
    
+1 for the "two or three active tasks" bit. I'd give you more if I were able. –  JUST MY correct OPINION Jan 9 '11 at 2:00

Yes programmers can get blocked, but not in the same way as writers. We get blocked because we're too close to a problem, or too far away. We just can't get the gray matter to pick a good path in the N dimensional maze that is programming. A break, a chat, especially describing the issue to a co-worker can work wonders. Note describing a problem will often cause your brain to see a potential solution, you need to chat to a willing sounding board but they don't necessarily have to be technical or know what you're talking about.

Writers' block is similar in nature but effectively a different beast. It occurs not because the author can't solve a problem but because the author can't get their mojo going, their inspiration is lacking, their muse is on holiday, the internal voices are simply telling them it's all rubbish, not even worth writing down. In addition it can last for days, months, years. The act of writing code and writing prose are superficially the same but they come from different parts of our spirit.

share|improve this answer
    
+1 for the explaining to others, so true. –  KeesDijk Jan 8 '11 at 8:26
    
+1 - also it might seem that with requirements provided, you don't need inspiration - but you still need to figure out how to implement. Sometimes some lateral thinking and inspiration is needed to choose a good solution. Without it, you may end up with something overcomplex, unreliable and unadaptable. The question is... do you know that you need that inspiration? Or if you think you're blocked, do you actually just need to get on with the obvious step-by-step solution? There's no easy way to know when inspiration is needed, except when it arrives - which is sometimes too late. –  Steve314 Jan 8 '11 at 11:18
    
+1 for rubber ducking. –  Corey Jan 8 '11 at 19:55
3  
I think writing prose and writing code come from the same parts of our spirit, just that we get more feedback when we're writing code. When you write prose, you might be weeks away from showing it to someone. When you write code, you're a command away from executing and seeing if you're closer to your goal. The blocker is the same in both cases: discouragement, feeling like you're not making progress, not making something of value. I've always found that stepping away for a while, and letting your thoughts clear up does wonders for both blocks. –  Steve Goodman Jan 8 '11 at 19:59
2  
You're saying people who write programs don't hear voices telling them "Your code is rubbish! It is not worth writing down!" ? –  Mark C Jan 9 '11 at 3:20

As someone who's been an amateur freelance writer (of sorts) and gone through writer's block before, here are my thoughts:

I essentially agree with MrTelly. But just to make it loud and clear: programmers block and writers block are different beasts because they actually come from different causes. Programmer's block is, in most cases, a technical issue of being too close to a problem and "not seeing the forest for the trees", and convincing yourself that you're on the right track. ie Not stepping back far enough to consider an alternative solution.

Writer's block, on the other hand, is almost always a case of lack of inspiration. After writing, say, 50 pages on a given subject, you just feel like you've exhausted it, and like anything else you have to say will just be padding and/or rehashing the same subject matter in slightly different ways. But you still have a contract (figurative/internal or actual) to write another 50 pages, and you just don't know where this is going to come from, because your brain and soul are simply spent on dealing with the subject at hand.

All that said, early stage burnout can also feel like you have programmer's block. This is a whole other animal though, and has subtly different symptoms. But I thought it's worth a mention, because feeling like you have programmer's block is one of the early warning signs of burnout - most often accompanied by apathy (ie No longer truly caring about solving the problem, and just wishing it would all go away. And feeling like the job/project itself is totally pointless.)

share|improve this answer
3  
+1 Because having read that, what I'm experiencing right now is burnout, not programmer's block and this helped me to at least identify the problem –  Crippledsmurf May 18 '12 at 13:55

I guess they are similar in you can't get your work done, but as a programmer, it's easier to go to colleagues or the Net and look for solutions and/or get help. Not sure a writer has this luxury. If you're in a funk, and know what to do but just can't get yourself to crank out code, it may be more of a sign of burn-out.

share|improve this answer
1  
I hadn't considered burnout. Sometimes if you go to IRC for help, people are less than helpful and make you feel like an idiot which can make the problem worse. –  codecowboy Jan 9 '11 at 5:50

For me is usually bacuse, I've just had one too many nasty bugs to chase down, and I'm worried about making more blunders. Then, if I have avoided finishing a particular piece of code for a while, I end up with a great deal of anxiety about picking it back up. And the funny thing, is that that anxiety is there even if my break from finishing it had nothing to do with the difficulty of the task (often I had a higher priority task to do first). This is about more than the cost of the mantal context switch. I think it has to do with fear of making a mess of things. I think that fear may be warranted, because as programmers we are smart people interested in efficiently doing a task -and that means we take mental shortcuts. And most bugs are found to be caused by mental shortcuts. And the cost of finding a fixing them is orders of magnitude greater then the effort saved by the shortcut.

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.