Live data from Hacker News

Why Programmers work at night (2011)

swizec.com

21–30 of 35 posts

Re: Why Programmers work at night (2011)

#21

As a part-time freelancer who also has a full-time job, I often don't have a choice but to code late at night or early morning. I honestly hate working at night, simply because I often miss small things that cause silent bugs. On the other hand, coding at early morning (5-6 am, before my wife and kid are up) feels really great.

OT, but would you mind sharing how you got your moonlighting gig? I'm looking for something myself, but don't want to participate in the race to the bottom on the usual freelance sites.

Re: Why Programmers work at night (2011)

#22
post #3

"I think it boils down to three things: the maker’s schedule, the sleepy brain and bright computer screens." I think a lot of it boils down to being expected to perform in really noisy not-conducive-to-thinking environments (yes, open-plan office, I'm talking about you) At least, that's been my experience over the last 30 years.

Parhaps offtopic, but f.lux ( https://justgetflux.com/ ) adjusts the screen brightness when it's getting night/late... It's awesome for programmers :)

I don't like how it doesn't change the screen brightness. So I hacked together my own tool that uses DDC to control the brightness and color of the screen. However ... the nvidia driver (in Linux) crashes when you use DDC to much. The alternative seems to be pulling the DDC wires out of a DVI cable and using a alternative DDC controller ...

Re: Why Programmers work at night (2011)

#23

This is entirely anecdotal. I'm very very skeptic that "the most productive time" is very late at night (or waking up at 4am). Yes, there's some work done in the evenings (6pm-8pm) or at 6-8am, but that's more an indication of a noisy workplace or with multiple interruptions. And getting into some sort of "pushing the limits to focus" sounds very daft. Specially if done often, the quality of the work will be very bad…

> And getting into some sort of "pushing the limits to focus" sounds very daft. Specially if done often, the quality of the work will be very bad.

I find I'm more productive at certain types of tasks (including programming related ones) when I have a certain level of fatigue. My brain can be noisy even if the workplace isn't, and fatigue reduces that noise.

Even for my own anecdote, however, this absolutely does not generalize to all types of tasks, and absolutely does not mean "pushing the limits", and I'll certainly agree it can be a daft excuse for a daft mistake that will result in some really daftly written code.

Re: Why Programmers work at night (2011)

#24

I disagree that /all/ programmers can be more productive at 2am rather than 10am. Indeed, day-to-day Real Life[tm] stuff really does get in the way, and I myself have raged due to the frustration of having my concentration broken by e.g. my wife coming in asking some mundane question outwith the context of the problem I'm working on - it is literally a mental disaster when that happens. I'm of the opinion that it's m…

I completely agree. I used to have a fairly strange sleep schedule that moved gradually till I was finally waking up at 2 PM. I'd then spend one night/day without sleep to reset it. While I got plenty of uninterrupted time it wasn't very quality time. These days, I work remotely from Europe while the folks I work with, work in PST. That means most of my mornings/afternoons provide uninterrupted work time. I find that I get a lot more done and I can handle all my meetings post 5:00 PM.

Re: Why Programmers work at night (2011)

#25

This is entirely anecdotal. I'm very very skeptic that "the most productive time" is very late at night (or waking up at 4am). Yes, there's some work done in the evenings (6pm-8pm) or at 6-8am, but that's more an indication of a noisy workplace or with multiple interruptions. And getting into some sort of "pushing the limits to focus" sounds very daft. Specially if done often, the quality of the work will be very bad…

> And getting into some sort of "pushing the limits to focus" sounds very daft. Specially if done often, the quality of the work will be very bad. I find I'm more productive at certain types of tasks (including programming related ones) when I have a certain level of fatigue. My brain can be noisy even if the workplace isn't, and fatigue reduces that noise. Even for my own anecdote, however, this absolutely does not…

> I find I'm more productive at certain types of tasks (including programming related ones) when I have a certain level of fatigue.

For me, reaching that fatigue means going to the gym. I feel like the physical fatigue helps me to get into a form of mental focus and tranquility. Even though I usually hit the gym at 8PM and return circa two hours later, I can keep pushing code for at least three more hours.

I also play competitive video-games with my friends, who keep on saying that they play better during the nights. Most of them are not into sports, but they can still say to be mentally more focused.

Whilst I cannot really prove that I would produce better code during the nights, the matchmaking in the games do turn out to have a trend of win streaks. I succeeded to rank myself to the fourth topmost ELO pool by playing during mere midnights. To reach that rank from the previous one, it requires approximately 12 wins in a row, which is not an easy feat.

About the original post, I also reason staying up late because the time difference between US and my current residency is such that any Github issues, PR's or emails tend to be sent at about midnight my local time. By staying awake an hour or two more, I can deal with those tasks to wake up to a less busy day.

Re: Why Programmers work at night (2011)

#26
post #11

My view is that we work at nights / early morning because it's quiet. If I could manage to work in a quiet environment during the day, I would.

Yes, even at home, during the day you are interrupted by:

* Phones ringing and other such interruptions

* Lawnmowers or leafblowers

* Seemingly incessant construction with drills, saws, hammering

When the sun goes down, these distractions go away and you can concentrate.

Re: Why Programmers work at night (2011)

#27

Whilst I don't disagree with the points in the article, I think the primary reason for the increase in productivity at night is the 'soft' deadline - knowing that I really should go to sleep, but perhaps I can just finish off One Last Thing. I find the same effect from working in a cafe (I've been here a while, I really should free up this table), or even just from drinking lots of water and needing to go to the bath…

This is entirely consistent with my experience since I was a teenager.
Post reply on HN