• Forum
  • Lounge
  • What should we do when getting stuck/ pa

 
What should we do when getting stuck/ panic in programming?

May 26, 2012 at 5:47pm
i believe every programmers here must have time when feeling panic, or getting stuck in programming...just wondering what you doing when having this situation.... feel free to drop your experience or comment here...
Last edited on May 26, 2012 at 6:42pm
May 26, 2012 at 5:55pm
At work, continue working on something else. At home, go to sleep.
The next time you get back to the code (or when you wake up), the solution to the problem will often be obvious (be it an unresolved bug or a matter of design).
May 26, 2012 at 5:56pm
This topic should really be in the lounge, not the beginners forum (not intended to sound mean or condecending; just for future reference)

When I have a problem with some code, I'll try debugging for a few minutes. When I can't think of anything else to do, and if the problem still exists, I do something else for a while, like listening to music (I find that helps me the most) or taking a short walk.
May 26, 2012 at 6:43pm
i moved this topic to lounge ^.^, thanks for the comment..
May 26, 2012 at 6:59pm
If I am stuck because I don't know how to proceed, I grab a teammate or two, walk up to whiteboard or into a small conference room, and discuss the problem I am facing. Software development (in the jobs I've had) is a group effort.
If I am stuck because I don't feel like working, I grab a coffee.
May 27, 2012 at 2:39am
closed account (3hM2Nwbp)
In the summer-time I'll hop on my kawasaki and go for a ride to clear my head. In the winter-time, I'll usually just have a drink and turn on netflix until it clicks.
May 27, 2012 at 3:44am
I just let my cat walk all over my keyboard and force myself to figure out what was meant to be there and what wasn't. Usually I end up finding the bug. :)

No, seriously. If I find myself seriously stuck (which thankfully doesn't happen to often), I take a break from the project for up to a week, then come back to it and try the problem from a completely different angle.

-Albatross
May 27, 2012 at 8:35am
I just let my cat walk all over my keyboard and...


That was probably the cause of the bug to begin with. Damn wily cats.
May 30, 2012 at 11:40am
I just smoke some cigarettes, eat, etc.

The thing is that when your brain tries to do something, it tends to make deeper the wrong idea, instead of thinking in something else. Well at least it happens to me.
May 30, 2012 at 11:55am
closed account (zb0S216C)
Bang the kettle on, grab the dodgy digestives, sit back and relax - simplicity itself.

Wazzak
May 30, 2012 at 2:08pm
[Edit:] This is for bugs mostly:
If there is no one around I cry, shout, hit and kick at the wall.

Then I go back to work. Usually, after a while, the problem is still not solved.

Then I cry shot, and hit the wall some more, and again back to work.

I do that until I find solution or my brain shuts off for sleep, in which case I restart the exact same routine immediately when I wake up.
Last edited on May 30, 2012 at 2:11pm
May 30, 2012 at 3:20pm
I agree with what mostly everyone else has said. Do something else for a while and then go back to it. (including going to sleep and waking up the next morning)

By the way, This is all assuming you have the time to do so, deadline wise.
May 30, 2012 at 3:29pm
closed account (1yR4jE8b)
When I'm at home, I start playing a videogame or watch movie to clear my mind.

When I'm at work, I grab a glass of water and walk around the office a bit with a pad and paper and try to work out the problem by hand.
May 30, 2012 at 8:05pm
darkestfright wrote:
walk around the office a bit with a pad and paper

I've found this to be quite useful for me as well. It seems I get my best ideas when I'm walking around, not actually at my computer.
Topic archived. No new replies allowed.