Coding Horror

programming and human factors

Geek Diet and Exercise Programs

Software developers aren't typically known for their superior levels of physical fitness. I'm not overweight, exactly, but I don't think I'll be pursuing that dream career in male modelling anytime soon. I charitably call myself an indoor enthusiast.

Tan Lines From Typical Summer Activities

At the risk of generalizing-- yes, I know you happen to be the exceptionally fit software engineer that proves the rule-- being tethered to the machines we love so much often leads to a sedentary lifestyle for programmers, and a high occupational correlation with obesity.

But it doesn't have to be that way. If we can whip computer software and hardware into shape, we should be amply equipped to whip the body's software and hardware into shape, too. Consider the advice of John Walker:

I'm an engineer by training, a computer programmer by avocation, and an businessman through lack of alternatives. From grade school in the 1950's until 1988 I was fat--anywhere from 30 to 80 pounds overweight. This is a diet book by somebody who spent most of his life fat.

The absurdity of my situation finally struck home in 1987. "Look," I said to myself, "you founded one of the five biggest software companies in the world, Autodesk. You wrote large pieces of AutoCAD, the world standard for computer aided design. You've made in excess of fifty million dollars without dropping dead, going crazy, or winding up in jail. You've succeeded at some pretty difficult things, and you can't control your flippin' weight?''

Through all the years of struggling with my weight, the fad diets, the tedious and depressing history most fat people share, I had never, even once, approached controlling my weight the way I'd work on any other problem: a malfunctioning circuit, a buggy program, an ineffective department in my company.

John compiled his advice into something he calls The Hacker's Diet. According to John, all we need is:

  • An eye firmly fixed on the goal.
  • Will power.
  • A high tolerance for pain.

In other words, we are so totally screwed. Jeremy Zawodny used the Hacker's Diet as a template, and came up with this kinder, gentler set of diet advice that's a bit less intimidating:

If you're seriously thinking about trying to lose weight, give this a shot. It's one of the easiest non-fad and non-gimmick plans you'll run across, mostly because the "plan" is very simple and tangible. It's not quite "the simplest thing that could possibly work" but it sure comes close:

  • Small changes have a major impact on weight loss because they're compounded over time. It's just like saving for retirement. The sooner you start doing just a little bit every day, the better off you'll be.
  • Anyone can do this. Anyone.
  • The process is self-reinforcing once you start to see real results. That means you need to commit to a month--a very difficult month. After that first month, though, it's easy. And the more weight you have to lose, the easier it is.
  • During that first month, you'll be developing three new habits. Only one of them is likely to conflict with an existing habit. The other two will consume maybe 5 minutes of your daily routine.

Like any proper geek diet program, Jeremy's is powered by a spreadsheet. In the end, it's basic math -- calories in minus calories out. Since programmers are legendarily obsessive, tracking everything we eat is a natural fit for us.

But reducing calorie intake through diet is only half of the equation. The other half is increasing calorie burn by exercising, or at least staying moderately physically active. A contributor to OmniNerd wore a heart rate monitor and measured exactly how many calories he burned during typical daily activities:

  • 100 calories burned per hour sitting in a chair "working"
  • 5 calories burned riding an elevator up twenty-seven flights
  • 100 calories burned per hour watching TV or surfing the Internet at home
  • 750 calories burned for eight hours of sleeping
  • 220 calories burned in twenty minutes walking 11/4 miles downhill to my bus (+50 calories burned "cooling")
  • 60 calories burned walking one New York City block (west-east) (+10 calories "cooling")
  • 25 calories burned walking up five flights of stairs (+35 calories burned "cooling")
  • 315 calories burned walking 11/4 miles uphill from my bus (+75 calories burned "cooling")
  • 150 calories burned walking a dog for twenty minutes (Note: It was a slow walk, the dog is very old.)
  • 660 calories burned in forty minutes of weightlifting
  • 900+ calories burned in fifty minutes on an elliptical trainer

It's a reasonable set of advice: eat less, exercise more. We may do it more analytically than the average joe, but it's nothing you haven't heard a dozen times before. The problem is getting off our collective butts to do it. It's difficult to get motivated, particularly when exercise almost by definition draws you away from your obsession.

But what if we could combine our computing obsession with exercise?

geek-a-cycle

Now we're talking.

The geek-a-cycle may look vaguely ridiculous. Still, I've often wondered if there was some way to combine all that time I spend sifting through content on the internet with some kind of physical exercise, instead of passively sitting in a chair. It's an interesting concept.

Greg used a similar recumbent trainer arrangement to lose weight while playing the massively multiplayer online game World of Warcraft.

warbiking setup

Greg calls this "Warbiking". It's a clever symbiosis of carrot and stick that really worked for him.

One of the bad parts of Warcraft is it can really suck you in - I tend to lose track of time and get pretty unaware of anything but the game. It's addictive as hell! One of the bad parts of doing Cardio is that it is very boring, so I tend to be very aware of how much I'm not enjoying it and how slow time seems to get. And I hate doing it!

Warbiking is the best of both worlds. I get to do 2+ hours of cardio without being aware that I'm really doing it. And as I can only play Warcraft while doing cardio (that's a self imposed rule - no cardio, no Warcraft), it's self regulating. No way am I going to play for 6 hours; my legs wouldn't do it. I did hit 4.5 hours one insane Sunday afternoon, but I won't be doing that again any time soon.

If you're more of a console gamer, there's the Gamercize. You insert the device between your controller and your console. The device monitors your physical activity, and will disconnect your controller if you fail to sustain a certain minimum level of physical activity.

gamercize in action

The gamercize is appealing because it's universal. It works with any game, but it's not exactly interactive.

Perhaps the best example of a game that integrates physical activity with actual gameplay is Dance Dance Revolution.

Dance Dance Revolution feet

DDR is one of the few games my wife enjoys playing with me. It's available on every platform under the sun, and even has a free open source PC equivalent in StepMania. The songs have a wide selection of skill levels, from ultra-klutz to ninja. If you can get past the natural aversion most people have to making themselves look ridiculous while doing something approximating dancing, it's really quite entertaining. And it's definitely a workout.

You might argue that none of this is really necessary. Wouldn't it be easier to drop all the diet spreadsheets and electric exercise contraptions and cultivate a traditional physical activity as a hobby? Say, something like soccer, or tennis, or cycling?

Sure. It would be easier-- if don't you mind losing all your geek street cred in the process.

Written by Jeff Atwood

Indoor enthusiast. Co-founder of Stack Overflow and Discourse. Disclaimer: I have no idea what I'm talking about. Find me here: https://infosec.exchange/@codinghorror