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.

Let me put this straight. I am quite passionate about programming. I am single and have plenty of time outside work. I haven't slept for 5 full hours for at least a month, as I am involved in multiple projects at work (most of them volunteered) and some open-source projects as well. I know that I am not a gifted programmer and work at a slower phase, but I always get a high (like what runners get) when I see my code working and being used by people. This high is driving me work crazy of late, as other aspect of my life like dating, meeting up with friends, workout takes backseat.

Apart from a great reputation I enjoy at my work place, there is nothing to show substantial :-( I can barely sleep, as my mind keeps bouncing ideas even when sleeping. Also, I crave for people's attention at work these days to make up for my personal life and this makes me take up other's work as well. Everyday I start telling myself to work for fixed hours and focus on other beautiful aspects of life, but indeed fail miserably. I know all this sounds like a big rambling, but Iam sure there are people in this forum who would've went through a similar phase in life. How did you overcome it? I don't want to be nerd with no friends. I have been working for 6 years after school and 27 years old male.

How to maintain normal life when your work and passion has become your obsession and addiction?

Update:
Thanks for all the wonderful answers posted. It really helped me to put things in perspective. I definitely feel better now and signed up for gym few days back. Also I leave my work laptop at office, to avoid working late at nights:-) Anyway I started sleeping for 8 hrs and it feels good. Working out regularly feels great :-)

share|improve this question

closed as off topic by Yannis Rizos Mar 8 '12 at 13:38

Questions on Programmers Stack Exchange are expected to relate to software development within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here.If this question can be reworded to fit the rules in the help center, please edit the question.

4  
en.wikipedia.org/wiki/Workaholic –  user281377 Nov 16 '10 at 21:08
54  
You are headed straight for a crash. With less than five hours a sleep a night, and foregoing workouts, you're in for a long phase where you can't stand the sight of code if you're lucky. At this point, I'd suggest consulting a doctor, since you are apparently out of control. Alternatively, take at least a two-week vacation somewhere else, and leave all computers at home, and see a doctor if that fails. –  David Thornley Nov 16 '10 at 21:23
4  
@rajachan - I've noticed that you have not responded to any of the great answers below which advocate slowing down and taking better care of your health. Please take them seriously - I know of cases where people in their 30s have had heart attacks because of sleep deprivation. Please take this as coming from someone concerned for a fellow programmer. –  talonx Nov 17 '10 at 4:43
6  
I'm prodding you to re-visit this question and look at the advice given. This isn't about anything so inconsequential such as votes. I honestly want to know, how are you doing now? You did, after all, shoot up a flair. You are also free to contact me, my info is on my profile. –  Tim Post Nov 17 '10 at 15:32
1  
Can't believe that this great question is closed as "off topic". I have seen many programmer colleagues get into this rut, and any advice such as these would be welcome to them. At least make this question into a community wiki so that it will stay around. –  tehnyit Mar 8 '12 at 13:53
show 10 more comments

13 Answers

up vote 41 down vote accepted

I spent about 2 full years in the exact same situation at the age of 25. I was behind the screen for at least 12 hours each day, in the end even more. In the beginning I still had other hobbies, mainly sports and a rather unhealthy partying habit. After a while I started to abandon those: they seemed like a complete waste of time while I could as well be programming (and at the smame time drinking espresso and smoking).

It's simply called addiction. The sad thing is I was not in denial but fully aware of what was going on, and you are as well obviously or you wouldn't have asked this question. However I did not do anything to stop it except for thinking 'yeah yeah next week I'll do somthing else'. You have to take the chance and do something about it. Not next week, not tomorrow, but now.

At the end of those two years things started to get really ugly. I looked like a zombie, behaved like one as well, especially socially, and (in my mind) worst of all the quality of my code was degrading quickly as I could not think clear anymore because my brain was in overdrive every single moment it was awake. Everything I wrote still worked, but it was overly complicated and had way to much unneeded functionality. I would try to stuff all patterns I knew in the simplest program ;P And yet, I just kept going. Until one day I crashed pretty hard. I'm not going to describe how, but it was an experience I would not even want my worst enemy to undergo.

To answer your actual question: I came over it by switching from one bad addiction to several other 'good' ones. From one day to the other I banned all programming outside work hours. The vast amounts of free time that became available like that got filled up with music, sports, movies and seeing friends. People tend not to believe me when I call these addictions, but let me assure you one week without any of them, especially the first two, make me stressed out. I also made sure to eat decent food, drink max 2 coffees a day, heavily limit smoking, barely drink alcohol, take no other drugs at all and go to sleep/wake up at regular hours. Also half a year after switching to this lifestyle I met a girl and we're still happily together.

I do not know if this can work for you: for me it did, but only for two reasons: I could only do it from one day to the other because first I learned the hard way by crashing, and the method of replacing one addiction with ohers only works because I know from myself that I'm pretty keen on addictions. Btw now I sometimes allow myself to do some small projects that are not work-related, and it's so much more fun than it used to be. But I still have to take care not to get sucked into it to much.

share|improve this answer
1  
Thanks for a great answer. I can really relate to you and it's nice to know that, people were once in that same boat and eventually came out of it.Btw why do great companies look for people who can code outside their work? Isn't a little bit unfair for companies to have this expectation? –  rajachan Nov 17 '10 at 5:43
3  
good point. I guess their idea is: is someone spends time coding outside their worrk, they must be very passionate. But there are at least two things wrong with this thought: 1 people can be extremely passionate about programming without doing it in their spare time and 2, as proved by this question, people might as well be too passionate. –  stijn Nov 17 '10 at 8:51
2  
Better than an addiction to WoW. –  mathStudent Jul 12 '11 at 2:15
add comment

No.

You can't have a life outside of work if you're sleeping 5 hours, working 9, and coding the other 10.

side-rant: This is the apotheosis of the expectation of significant side-work for passionate programming, which is a foolish way to approach a life, as you are becoming acutely aware.

I would recommend doing several things, in increasing order of severity -

  • Cut your volunteering down to projects that really matter. Most software has very little effect on things that really matter. Like you said, nothing really substantial has been to show for it.

  • Work out 3x a week, and sleep 7+ hours per night. Work out in a serious fashion so that you are tired when done. This will help you sleep. Add in some healthy eating.

  • Find a new non-technological hobby. Cooking, carving, weaving, gardening, music, chess, skiing, hiking, etc.

  • Burn down your vacation time and go to the mountains. Don't take any computational or connection device with you. Do take your preferred religious writings- on paper, not a Kindle. :)

  • See a mental counselor(quality of these can vary widely, you may have to shop around for a bit). A trusted family member is a reasonable choice as well, as is a trusted priest-type.

  • Find someone to date and learn their hobbies.

FWIW, I struggle with the compulsion to code as well - the best cure for me is spending time with friends or my fiance.

share|improve this answer
1  
This is the first day I've seen the word "apotheosis", and I've seen it twice today! What's up with that? Great answer, by the way! –  Joey Adams Dec 7 '10 at 4:36
add comment

You overcome part of this by recognizing that your health, which has both physical and mental aspects to it, should be important. This means things like eating, sleeping and exercise are required for your body to be at optimal efficiency and effectiveness. The other question is beyond programming what other passions do you have? Looking into pursuing those may be an idea but you may have to view this as a programming challenge: Can you figure out how to make sure you call this friend or talk to this relative, etc. be done on a consistent, regular basis? There is an aspect here that is self-preservation though another side is what other goals do you have in life beyond getting recognized for having working code? You do realize that most of your code may not last that long, right? I know there are some rare exceptions where something is like an Energizer bunny, but a lot of the time it seems that most things eventually get rewritten which isn't a bad thing to my mind.

share|improve this answer
7  
+1 for HEALTH. @rajachan, sleeping that little is going to ruin your health in ways that you can't appreciate until it is too late. Nothing is worth that. Get a solid 7-8 hours of sleep every night along with at least 30 minutes of exercise every day, and what talents you have will be much-better applied than if you are a sickly wreck. –  Adam Crossland Nov 16 '10 at 21:23
add comment

I suggest spending some time researching the effects of sleep deprivation. Many people here understand what drives someone to go on a creative binge. Many of us have pulled consecutive caffeine driven all nighters. They aren't healthy, but a two day stint followed by a sufficient amount of time to recover isn't going to hurt you.

What you are doing is asking your body to do things that it wasn't designed to do. It will try to do what you want, it will send you warning signs and then it will begin to fail. If you keep going like this, the following is very likely to happen:

  • You'll start getting very paranoid. The more you force yourself upon your peers for approval, the less approval you'll receive. This will lead to depression and may make you try even harder. That will start ranking you on the sociopathic scale, even if you aren't. As a programmer you must know, it is hard to distinguish benign behavior from malice in some cases. Is that guy off his rocker or just having a breakdown? I had a breakdown once, it was a very unpleasant experience.

  • You'll start hallucinating, eventually. If you are at all religious, or perhaps interested in metaphysics, watch out.

  • You'll start blacking out. Your brain is in charge, if it decides that it has to sleep in order to protect itself, it will release enough melatonin to knock you out despite your best wishes. This might happen while driving, riding the bus / train or any other very bad time. Watch out. Ever see a drunk pass out? Hint, that was because the drunk's brain was protecting itself.

  • You'll stop retaining most of what you read and almost everything that you hear. Work will become very interesting. People will point out that you are repeating yourself and not completing assignments.

Your body will eventually put an end to the nonsense by just refusing to cooperate with you. At that point, you can either decide to live a healthy life style, or use chemicals to help you continue with the one you have. It is very easy to become addicted to a very bad (but self serving) life style. I suggest treating 'urges' as a drunken monkey and dealing with them accordingly.

You need to decide, right now, that you can't possibly be equally or more skilled than everyone around you overnight. It's not like you can invest a few months of really, really unhealthy living into acquiring super skills.

If you want to get better at what you do, try the following:

  • Live healthy (sleep well, eat well, exercise well)
  • Interact with humans, if only to deepen your appreciation for deterministic machines
  • Get to that magical place they call outside each day.
  • Don't ask your brain to retain much beyond 10 hours of using it

There's nothing wrong with using some of your spare time to write code. Lots of us do that, because it's what we love to do. But we also do other things, too.

I'd slam on the breaks hard, now and take a few days off to recover. As others have suggested, there is absolutely nothing wrong with seeking medical help to get yourself back on a sensible track.

share|improve this answer
3  
Excellent information. I have lived through all of the sleep-deprivation effects described here, and it's not a good deal. –  Adam Crossland Nov 17 '10 at 14:11
add comment

I have a few friends like you. They are older though. They use their work/volunteer obligations as an excuse to avoid addressing their personal lives (or lack thereof). Dont become them. Go on a dating site and meet a nice significant other. Having someone else in your life will help balance out your personal & work lives.

The sleeping thing... that there are some ways to address. The problem is programming is very visual, and between staring at a bright monitor and thinking about algorithms, it keeps the mind active, hyperactive even, sometimes to the point of not being able to shut it off.

To help avoid this, stop all computer use, and preferably TV viewing, at least an hour before you go to bed. Read for an hour. Something non-computer related. Fiction, for example. Or even listen to a book on CD. That will set your mind into a different mode, and allow you to sleep. Also, dont do anything other than sleep in bed (there's one other allowable exception, but it doesnt sound like thats an issue for you). Read/work in another room. Bed is for sleeping only.

share|improve this answer
2  
Good advice, but I'd add: get your head at least a bit more in order before you go looking for a partner. You'll have a better idea what you want, and you'll be more attractive to those people, when you are more fully yourself. I don't mean wait until you're perfect, just get through this crisis. –  poolie Nov 17 '10 at 4:39
add comment

"Everything in moderation."

Constantly remind yourself that burn-out is not fun and bad for your health.

Definitely consider taking a real vacation. I.e. a resort someplace and leave the laptop at home

Definitely consider seeing a doctor and/or psychotherapist.

Get your butt in a good yoga class, ASAP! By good, I mean one that goes into the non-physical aspects, e.g. meditation.

(Just a few ideas off the top of my head, since I can't seem to pull it together into a better write-up right now and others are beating me resoundingly in that aspect.)

To actually answer the question in the title:

Yes, a passionate programmer that isn't necessarily a rock star programmer can indeed have a life outside of work. If you can't, then maybe you should consider another role, e.g. technical project manager, and leave the programming for a hobby. However, it doesn't sound to me like you're making up for your lack of ability. Rather, you are overdoing it, like a rat pressing a lever in order to get that cocaine. Don't be the rat. They usually die. :)

share|improve this answer
    
+1 for yoga, it is a great help to calm one's mind. –  Péter Török Mar 29 '11 at 8:32
add comment

Do you have ups and downs? Do you have days (or weeks) when you feel incredibly productive, followed by days (or weeks) in which you feel like doing absolutely nothing?

If so, you may have bipolar disorder, also called manic-depressive. You have bouts of mania, in which you get little sleep, get a lot accomplished, and get a high off doing work. Then you crash, sleep a lot, and maybe even feel suicidal. The cycle repeats.

If this sounds like you, please see a doctor ASAP. Actually, just see a doctor whether or not this seems like you.

I've nearly lost two friends to bipolar disorder because when they were depressed, they wanted to kill themselves. One tried to jump off a bridge, the other wanted to shoot himself and his family.

share|improve this answer
add comment

Set goals.

  • Have goals for each aspect of life: professional, health, personal, relationship, social, etc.
  • The goals should be concrete and measurable.
  • The goals should have a deadline.
  • They should be difficult, but not unreasonable to achieve in the given time frame.
  • Write the goals down. Check the list frequently and update it with your results.
  • Share your goals with others. Peer pressure (the good kind) is a wonderful motivator.

Example goals:

  1. Health: run a mile in W minutes, deadlift X lbs, bodyweight of Y lbs by date Z.
  2. Professional: finish project X and get a raise of at least Y dollars by date Z.
  3. Personal: X pages of writing (diary, blog, short stories) each month.
  4. Relationship: visit at least X new places with my girlfriend by the end of the year.
  5. Social: Try at least X new bars with friends this summer.
share|improve this answer
    
You said that we should have a goal for each aspect of life, but you seem to treat personal life like a professionnal business (measurable, deadline). I don't say it wouldn't work, but it sounds weird. –  smonff Mar 25 at 3:07
add comment

I feel like I'm in a similar boat. I'm at my last year of college, and I just quit an addiction to adderall about a few months ago. I was so happy that I got so much done at first, and it made me feel like I could do anything. However, when I was off it, I would have a complete opposite reaction and I couldn't do anything. My desire to be productive overrode my thoughts for personal health, and when I realized how bad amphetamines were for you (and starting to look like a skeleton), I stopped taking them with my girlfriend's help. Even though I still can't accomplish as much in a day, I feel like I'm ultimately happier.

If you're concerned about being able to complete things, what works for me is setting small goals for myself each day, and working to accomplish them. Those small projects are part of big projects, and one day, hopefully, they will come together and I'll have really made something cool.

share|improve this answer
add comment

I'm not sure why you're so worried. You have found something you love to do and you do it as much as you can. This should be completely normal and accepted. No one truly great is "well rounded", everyone must focus in order to achieve greatness.

I say keep working hard, stack up money and expertise, and worry about your social life when you need to escape from computer programming, which is clearly your calling.

share|improve this answer
5  
No offense, but this is horrible advice. He's been at it for 6 years, can see that there's a problem and most likely headed for serious crash. –  George Marian Nov 16 '10 at 21:49
1  
-1 for advice that Alfred E. Newman would give. –  Adam Crossland Nov 16 '10 at 21:49
2  
@George No offense, but the shrill Momma Bear tone in this thread is pitiful. He's been doing it for 6 years, it's obviously sustainable. Let him do what he loves! –  Chris McCall Nov 16 '10 at 21:56
1  
What a polarizing issue. I got downvoted too for a similar advice. It's either achievement or healthy ("healthy") life but rarely both, though not impossible of course. A superachiever's social and physical life will be settled sooner or later anyway. –  mojuba Nov 16 '10 at 22:08
1  
@Chris, much like falling out of a window on the 100th floor. The first 90 floors falling go faster and faster, and without much effort. Then comes the crash... –  user1249 Nov 16 '10 at 22:29
show 1 more comment

Just like my middle school band teacher taught me - "Nobody can 'find' time, you have to make the time" to do whatever you need to do. Here that would include doing otherthings to avoid the crash everyone else describes.

If nothing else, go for a 30 minute walk or jog after work. You're permitted to think about programming if you like. At the very least, it will help you sleep longer.

share|improve this answer
add comment

There are some good answers already, but I'd like to suggest three simple things:

1) Get a health checkup.
It's not necessarily bad to sleep in <5 hour chunks - but you're very unlikely to get away with only 30-35 hours sleep a week without suffering negative effects.
Talk to a doctor, find out how your body is doing, and do whatever the medical professional tells you to get it performing effectively.

2) Find a social hobby.
Find something that will allow your brain to relax (or at least work in different ways), and preferably one that involves going outside at least some of the time. (sunlight, fresh air, exercise - all very good for you)
You want something that has regular times every week - maybe get some friends and/or work colleagues to join you - at the very least tell them all about it, so they can help make sure you go - and stick to that appointment as a #1 priority with no excuses.

3) Change your programming habits.
See this question and look for others like it - the key thing is taking a break every X minutes, in order to improve your focus and get more work done. Work smarter, not harder. In addition, spend less time programming, and more time learning - you don't need to be gifted to be a good programmer: almost everyone has to learn, and it's not that bad, once you get going.

share|improve this answer
add comment

What drives you at this stage of your life is some hidden motivating force in your subconsciousness. As someone who'd been through this many years ago, I'd suggest that you let it flow for a while. Aside from many benefits such as gaining experience at an enormous rate, theoretically there is one danger: to become a workaholic for the rest of your life. But I don't believe in this. At certain age and at certain level of expertise in programming particularly you realize that you can achieve more by doing less. That's where it starts gradually calming down.

Be patient in other words, your mind knows something when it drives you to work like crazy. It is temporary anyway.

share|improve this answer
1  
Thanks for the great advice. I particularly like the "achieve more by doing less" part. –  rajachan Nov 16 '10 at 21:21
4  
Less than five hours of sleep every night for a month? This isn't nearly as temporary as it needs to be for rajachan's health and general well-being. –  David Thornley Nov 16 '10 at 21:34
    
@David is correct. Regardless of what his mind is driving him to do, his body has to be able to cooperate. Human beings simply aren't meant to get by like @rajachan describes. –  Adam Crossland Nov 16 '10 at 21:42
add comment

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