Why programmers work at night

Published on December 22, 2011

Why programmers work at night

Original author: Swizec Teller
  • Transfer
Chimpanzee brain at the London Science MuseumAccording to a saying, programmers are devices that convert caffeine to code.

If you ask the first programmer that comes across when he is most productive, he will most likely call night. Someone early, someone later. The popular option is to get up at 4 in the morning and do the work before the start of the daytime turmoil. And some prefer to go to bed at 4 in the morning.

The purpose of all this is to get rid of distractions. But one could just close the door ... What is so special about the night?

I think it comes down to three things: the creator’s schedule, the carotid brain, and the bright computer screen.


Creator Schedule


In 2009, Paul Graham has written about the " schedule creator » ( maker-'s schedule ). In his opinion, there are two main types of schedules in the world. In the traditional “manager’s schedule”, the day is divided into separate hours, and a ten-minute hitch costs a maximum of an hour of lost time.

ClockworkAnother option Graham calls the schedule of the creator - the one who creates, creates, produces something. Work on large abstract systems requires placing them entirely in your head. This can be compared to building a house of crystal : it is worth distracting, as everything crumbles and shatters.

Therefore, programmers are so annoyed when they are distracted.

Because of this enormous mental contribution, we simply do not start working until we can count on a couple of hours of rest. It makes no sense to build in your head a comprehensive model of the system only so that after half an hour someone breaks it.

In fact, talking with company executives you will find out that they simply cannot finish any work during the day. The constant cannonade of clutter: important matters ™, requiring attention, and letters, requiring an answer, simply do not allow anything to be done. Therefore, they do most of the work at night when everyone else is sleeping.

Carotid brain


But even programmers need to sleep at night. We are not some superhumans. Even programmers are more attentive during the day.

Ballmer PeakThen why do we do the most difficult mental work when the brain wants to sleep, and simpler tasks - when the mind is sharp and clear?

Because fatigue makes us better coders.

As with Ballmer's peak, fatigue forces us to pack because a tired brain is simply forced to concentrate! He simply does not have extra forces left to allow himself to lose concentration.

For example, my productivity is minimal after an excessive amount of tea or an over-consumed energy drink: they make me hyperactive, and I check Twitter or read Hacker News, in general, I just jump back and forth.

It would seem that I should work better - so much energy, such an overclocked brain. However, instead, I myself am confused at my feet, because I can’t concentrate for more than two seconds.

On the other hand, when I'm a little tired, I just plop down at the table and write . With a slightly tired head, I can write the code for hours without even thinking about peeking at Twitter or Facebook. The Internet seems to cease to exist.

I think this is true for most programmers. Our mental powers are redundant for ~ 80% of tasks: you must admit that the implementation of an interesting algorithm often requires writing once again ten times more volume of auxiliary code. Even if you are doing the most complex machine learning you can imagine, a big piece of work is just preparing the data and outputting the results in a beautiful way.

And when the brain does not work at full capacity, he is looking for something to do. Fatigue dulls the mind so much that it becomes enough for one current task.

Bright computer screens


Everything is simple here. Keep staring at the bright light source in the evenings, and your sleep pattern will begin to linger. You forget about fatigue until three in the morning, then you wake up at 11, and when evening comes, you simply are not tired, because you have only been up to eleven in the morning!

Night InnsbruckAfter several repetitions, this approach will easily drag you into a different time zone. Interestingly, the shift is not infinite, and once falling into the equilibrium bedtime between 3 and 4 hours, you will usually stay there.

And maybe the thing is the alarm clocks that raise us in the mornings, because the society calls us lousy lazy people if we start breakfast at two in the afternoon.

Conclusion


So, programmers work at night, because it does not require to stop working at a certain time (which allows you to work more relaxed), the brain is not distracted, and a bright screen drives away sleep.

Note translator : the first comment on the original article complements it well:
The real reason is that we spend time all day, and by midnight we switch to “Ahhh!” # $%! Work!"