This is exactly how I feel. That 1.5 - 2 hours each night when I know no one wants or needs me to do anything is invaluable for me mental health. I know I should get more sleep but I need that time to not resent the fact that I get so little time for "me". I get to work at 4:30am (time zone thing) and do a lot of the primary child care and chores. It's often 8:30pm before I'm done and even then the dogs water bugging me to go out, etc. My wife needs sleep so she heads up early and I just putter or stretch, sometimes I write a little code, or watch part of a show. Feels good.
Philip K Dick wrote about being out of the heat of God's light, not feeling the scorching heat of the palm tree garden upon us. I believe it was from one of the VALIS novels but I haven't gone back to dig it up, and could be wrong.
Personally, I find I sometimes have trouble accepting good enough solutions. I want more structure, a better defined start. At night I can drop into a productive flow state with much less resistance, ignore many of the day-time wants. The hours run short; let's seize what we can from the waking hours. As well that "inspiration," I think there is probably a physiological barrier lowering that happens as we go into the night. As we recede from the gods' light, as it were.
So much this. Specifically (for me), it's the simple understanding that I will not be disturbed for as long as I care to focus, so it's worth the "effort" to get in the zone. Which of course means it only takes 30 seconds to get there.
But the screwed up sleep cycles from years and years of this are starting to take their toll, so I've been trying everything I can to replicate that peace of mind during daylight hours. No silver bullet yet.
For a few months my wife had a baking job that required her getting up at 4. I’d get up with her and start to work after breakfast. I’d have the days work before 9:00 standup. More time for sport and cooking. Think it was a healthier lifestyle in total. Social life was impossible though, we couldn’t manage to stay awake long enough to meet up with friends. And impossible to maintain once she switched to another shift.
Being very much not a morning person, I get a taste of that too when I have jet lag traveling west. Even after the feeling of jetlag subsides after a few days, I tend still tend to wake up earlier for two more weeks or so.
It's a different world and definitely has advantages. However, like you, I'm not sure it's worth the tradeoff of being horribly tired long before my usual bedtime.
In total, I think I still prefer getting up late and sleeping late.
It’s definitely not science but, for me, time seems to flow more uniformly at night. I have pretty bad ADHD so I big time struggle with “time blindness” - have I been working for 40 minutes or 4 hours? I guess when it’s the middle of the night I don’t really need to worry about how long it’s been. I only need to know that I don’t have to be anywhere else at the moment and my only hard stop is when I can’t keep my eyes open.
My favorite working hours, of all time, are 11pm-7am. I get more done in that 8-hour stretch than any other.
There's less local news. There's nobody to call or text. There are no deliveries. Slack is quiet. My email is quiet. Our repos are quiet. The dev logs are quiet. My family is asleep so I know they're good. If I need a minute to think, I can sit on my front porch and not worry about being distracted.
Now that I have a young kid, it's really hard (and generally selfish) to work those hours. I miss it.
The number of @here IM pings I get on company chat during the day is insane, and usually none of them apply to me. Sometimes I have to just secretly schedule work that requires my absolute focus to the night time behind my boss' back. I shouldn't really do that - I don't get paid enough to - but anyway.
It might be time to just shut off slack for a few hours a day.
It's probably frowned upon in some places, but when I _really_ need to focus (during daytime hours), I generally shut down slack, email, my phone, etc.
Generally, the teams I've worked with over the years have been amenable to this. I try to promote it with my teams as well: actual time off (no popping in while on vacation or sick), good sleep, time for focus, shutting off slack - especially when not working.
The last thing any of us need is to burn out because of notification overload. It makes us a stronger team if we're all healthy, well-rested, and able to get things done.
Seriously too many distractions make work impossible. I can't seem to get this into people's heads. I need them to leave me alone when I'm working.
It's so bad that I've started to get anxiety every time I open my computer. I start to panic because I know a distraction is coming. It makes it so difficult.
I also enjoy this special time in the night. It's just 11pm in central europe. But I also know my child goes up tomorrow morning at 7am the latest, and if I keep working until 3 or 4am (which I regularly do), I will have a very bad next day hangover. It's the constant problem with too little time...
yah if you have the drive I think there's lists of projects open and welcoming to beginners etc. I don't know of any good curated lists but a quick search led to..
even 1 hr of productive, quiet concentration is better than 2 or 3 hrs of interrupted time. By interrupted time, i mean time that you _could_ be interrupted, not that you were interrupted.
I've had a few personal projects where I've spent several hours in the evening working to get it off the ground. What I've found is that my mind is so activated/stimulated that I then struggle to even fall asleep as the code is still dancing in my head. It's a real trade-off I have to make - stay up late to begin with to code on something and then another 45-60 mins to even fall asleep.
A few times I've had it affect my dreams. I was working on a toy OS a couple of years back. Similar to the OP I would work on it for a couple of hours every night after my girlfriend went home. One time after I was working on virtual memory I had a dream where I was in memory and there pointers and stuff. It was really weird.
They're really weird, up to being unpleasant (also had them when working on a toy OS, but once I also had an XML related one; cannot recommend).
However, they are downright tortuous if they come as fever dreams (though fever dreams are of course unpleasant no matter what the subject, and are often hard to willingly wake up from, since you're having a fever).
I’ve been having these weird crossover dreams where I’m in this stressful dialogue with myself about some personal problem in my life — but the dream’s visuals are all just code in an IDE window and I’m desperately debugging it to fix the personal problem. It’s pretty crazy.
The solution seems obvious. Work completely through the night, then collapse from exhaustion at your convenience! The trick is scoping out your projects appropriately so that you can finish them and catch up on sleep before going completely insane. :-)
I've done this a couple of times --- thankfully not for decades. But it's remarkable how much being a code monkey is timeless. You look up and months have passed.
This does not work for me at all. My mind is active in the evening, not so much in the morning. It's already hard enough to get up at a time that morning people still consider to be acceptable, getting up even earlier would effectively take time away, in total.
Different people have different cycles where they are alert and productive. About 2/3 of the population are "larks", most alert in the morning, go through a trough in the arternoon and return to some sort of creative/productive state in the early evening. About 1/3 are owls. They have their trough in the morning, the creative/productive phase during the day and the alert phase in the evening.
It's good to be aware of what type you are and what works for you. Conversely, recommending anyone just gets up earlier may be more harmful than helpful, depending on the person.
Ahhhh -bad times, when I was still programming for „fun“. Turned me into a „thinking in code“ zombie that had trouble dealing with people. Really turned my autism dial to max.
This. I used to spend 8+ hours a day coding (yes really) for work then ‘fun’. I often had a hard time around people in real life. It was like my nerves were on high gear and I was awkward and didn’t know when to engage the speech portion of my brain for normal conversation as if I was some observer. After not coding for a decade it’s much better. I can carry a conversation, especially after a beer.
Slow migration that just happened over time. I took an architect role that required technical knowledge but about 0% coding. Initially I was disappointed about that but went with it. Eventually I took a pure business role. Along the way I got better with people, still a bit of an introvert but able to fake my way through to an executive role.
Every once in a while I’ll try to code something. I’m able to get by if I want. I get bored with it quick though and it doesn’t bring me the same kind of flow buzz mental stimulation it used to.
I’ve gotta say though, the modern web wtf happened?
It's not quite clear from your last sentence but in any case, for German these „quotation marks“ are completely correct. For printed texts, I personally prefer the »guillemets« variant, they look more even and symmetrical.
Not that you asked, but the «French style» of guillemets is my favourite way to wrap a quotation out of all of them. Unicode has rather too many "quotemarks" and they all sort of run together. The German style of using them strikes me as aesthetically perverse, like the sentence is being pinched, or like a language which uses }braces like this{ !
Little typography nitpicking: the content inside the French quotes is supposed to be separated from the quote symbols by a (non-breaking) space, « like this ».
Interesting different aesthetical preferences voiced in this thread. :-)
As others already said, the French actually use the guillemets with thin spaces but the Swiss use them without.
But the outward pointing of the guillemets looks really odd to me. I like that the inward pointing guillemets basically scream "look at me, I'm a quoted part!".
Yes I am living in the German speaking area, but I have no idea why my browser produced smart quotes when I wrote my original text. Maybe I wrote it in another editor.
I didn't know there was “ AND ”. I hate those fancy/smart quotes. They are not internationally understood and confuse computers and people alike. Just like I wish we would all just speak English, I wish we would all just use """".
Do you mean semantically? I quoted "fun", because it wasn't fun. Diving deep into programming means letting a very specific part of your brain run rampant. The problem solving core of whatever. This hurts all other parts of your brain: especially those for movement and social stuff. I quoted "thinking in code" because it's a meme phrase created by a boy that writes hello world apps and got interviewed on TV -people online use it to make fun of "fake programmers". In the German area we use quotes around words or short phrases to make clear, that we don't mean what we just said. One can also do air quotes. Is that not done in the English speaking world?
Or do you mean the characters? Yes, I am indeed living in the German area and software here often uses those stupid, stupid "smart quotes". I believe we are also taught to write like that on paper. One opens, one closes the quoted phrase. Though I have no idea how this happened here, as right now, in Chrome, I can only produce "normal" quotes. """"
I am still trapped in the developer role and I don't really see the way out at the moment, but I hate it. I don't program privately at all anymore and I do my best to take on tasks at work that require no programming. If there are straight programming tasks, I just take as much rest as I need, which can be, relative to my normal fulltime working hours, a lot. I have become efficient enough to perform adequately even when doing that.
I've found this too. When I'm knee-deep in code, my brain gets locked into "problem mode" and it can't recompose itself for communicating with others like a normal human being.
I need a good 2-3 hours away from the problem before my brain relaxes and I can actually talk without sounding like I'm stoned or mildly autistic.
I have the same issue. If a personal project is fun, I might end up trying to 'just fix this one issue; just polish up this one feature' all the way up to bedtime.
This will invariably affect my sleep with either no sleep at all for 1-2 hours or dreams of fixing an issue over and over again resulting in me being less rested the next day.
I'd love for there to be a quick way to 'snap' out of programming mode but after over a decade of programming I haven't really found one (except for having a couple of pints...).
The dreaming of fixing an issue is funny.
You can take advantage of that by stopping when you are stuck. A lot of times your brain will cook up a fix during the night and it will be waiting for you in the morning! I haven't noticed that this makes the sleep less restful either.
You’re right that often times works, but I’ve backtracked on that - to the extent I’ll actively try and dream about something else - an island perhaps.
I’ve come to terms that, for me, hacking into the night, dreaming about solutions, then waking up and implementing them... is manic and deeply unhealthy.
I find the surface level of my programming dreams are exceptionally dull (`var a = b + c` for what feels like hours) but yes sometimes a solution to a problem occurs to me early the next day.
1. Batter my brain
2. Do something else
3. Sleep on it
4. Aha moment
I do it so often, I just say to colleagues that “It’s stewing in the back of my head for a bit” or “Need to sleep on it”.
Before I was fully aware of it, I’d get super disheartened, sleep on it, then come in the next day and nail it by 10.
That’s another thing: if something becomes comical, there’s usually a pattern. If it’s the positive kind of comical, repeat the pattern. If negative, consciously avoid (but that appears comically harder).
If you haven't tried it yet give note-taking/keeping a (work) diary a shot. Works well to get stuff out of your head and separates work from the sleep.
I've put a huge emphasis on sleep in the past year, as someone who used to sleep about 4 hours a night.
I've found that giving myself a solid hour to wind down helps immensely with slowing my brain down and letting me sleep more peacefully. Sometimes I read, or listen to music, or watch youtube, or have a beer or an edible and just hang with out, or just tidy the house or something. Whatever it is, it's not work, it's not in my office, and it's not hard. I've found I've been sleeping far better because of it.
Even on nights that I work super late on some head scratcher, with a full 12-15 hours at my desk, I still give myself the hour before going to bed.
This is how I do it, too. I allocate at least an hour to YouTube (in bed, using my iPad), with the not-super-strict rule to look at content that does not stimulate my mind. Videos about games, or restoration of old computers, are okay for bedtime, videos about e.g. DSP are not.
If my mind is really stimulated, this may feel a bit awkward initially, forcing my mind to "calm down and focus on the video", but at the end of the hour it's usually fine.
And then do not start thinking about a related problem again when you shut the iPad off. I made that mistake so many times.
You've probably heard this but the science says you'll "condition" your mind to sleep better if you associate the bed with just sleeping (and possibly that other thing). But try not to read, watch videos etc for extended periods of time in bed, and you will get naturally wind down and fall into "sleep mode" once you get in bed.
I do the same with my Boox Note 2, sometimes followed by reading a book on it (with the blue coloured backlight off and only the warm orange one on, it doesn’t annoy my partner with the lights off)
Take Ca+Mg supplements in order to improve sleep and reduce your stress level. It will make you slower at thinking but still functional, and after a few days you can switch back to normal.
For me this formula works like magic because I can't control my mind from constantly iterating when starting new projects so I use this as a chemical brake.
I mostly fast until dinner then I have a 2k calorie meal, I can barely stay awake until 10 pm after a hit like that, the rest of the day I’m super alert, use one super dark 16 oz (no dairy) coffee in the morning for appetite suppression.
For me there's a big difference in mental state between "getting it off the ground" and "working on little bug fixes or PRs".
"Getting off the ground" is for me, a great big open-ended architectural decision making process with an ocean of second-guessing myself. It's very very likely to keep me awake for hours reevaluating everything I did in that last couple of hours.
Smaller pieces of work are different. Actually fixing a bug has a fairly well defined "ending" and I can sleep easy basking in the warm glow of satisfaction. Even getting part way through implementing a feature is a thing that doesn't put my brain into "wide open exploration of all possibilities" mode. It's maybe not so easy to bask in achievement and sleep as a quick bug fix, but at least the "code dancing in my head" is a fairly narrow path of implementation I've probably already got the structural problems solved for.
Reading in bed is a good transition from active thinking. The book has to be something that strikes a balance between not too exciting, but not unreadably boring.
Flip side is when you sleep like a rock, because you can’t get started. My project stalled for the winter months. Now I’ve forsaken television (in favor of a book) just so I can get a 30 minutes to two hours of code time.
I did most of my computer science studies at night when the whole world was asleep. I have quite fond memories of finally finishing a piece of work as the sun was coming up and settling down to sleep at 6am. It was terribly unhealthy, but I learnt so much.
I guess I'm not sure what's left to do for a couple of hours every day on curl after 23 years (given that it fits into the unix philosophy of do one thing, but do it well)? Are there that many new features? Lots of bugs to fix? (I wouldn't guess so) Seems like it would only need a couple of hours of maintenance/month by now given the functionality.
I don't know the details of curl's development, but at least some of it must be just keeping pace with the shifting infrastructure of the internet: HTTP/2/3/QUIC/whatever, changes in TLS and the underlying libraries, that kind of thing.
> we add features, improvements and bug-fixes continuously. With 240 command line options , 26 transfer protocols and countless combinations of things done over a crazy Internet that's just the nature of it all...
That sounds like a bad architecture and a bloated app. It's like if VSCode decided "we don't do plugins, everyone commit your idea directly into our main repo"
A sensible plugin architecture would let you do either
curl --plugin=LDAP
or a naming convention would load the appropriate plugin based on the protocol.
Yes I know, armchair code design. And I also know it's nice not to have to deal with configuration, a large app "just works" (though FYI, it does have 15-20 dependencies which are similar to plugins, it has 3 direct and more indirect dependencies). But, 2hrs a day * 23years = 16790hrs!!!!! Something seems wrong for that much time to be spent on "curl"
Just to be clear, first, thanks so much for curl! And second, of course having not touched the code ever I have no idea why it required 16k hours of dev time and continues to require more, it could totally be justified.
I'm only saying that at a glance, 2hrs a day, 23years sounds surprising and it makes me wonder if there isn't some ways to reduce the load.
It's not about the bugs. It's about one person putting 16k hours time into it instead of 100 people each putting in 160hrs each (yes I know that's not how it works but something is arguably wrong if it takes 16k hours of one person's time for something like curl
Hiring practices demand it. Other qualifications being equal, who gets hired: someone who works on personal programming projects or someone who doesn't?
cURL and VLC, not to mention linux etc... really call into question for me the idea that market forces are necessary or even beneficial to good software. curious to hear what i may be missing by making this inference though.
Market forces do make for optimal software over the long-term, but it’s only optimal as an engine for generating capital. If what you want out of software isn’t aligned with what generates capital you’re not going to be happy.
I’m guessing most our our personal metrics for what makes software “good” are only somewhat aligned with capital.
Been doing this for years, working on Rust graphics libraries. What helps me sleep is just being totally exhausted. But focus at night is amazing, and motivation is very easy to sustain if the timing is regular. During the day, I keep thinking in the background what I can do in those 2 night hours, so when the time comes there is no procrastination. Feeling very productive this way.
I wish I had the energy for this. By late evening I'm so tired all I can do is read or watch TV and then go to bed. Perhaps when my daughter is a bit older and I have more spare time I'll be able to do work on hobby projects.
Getting up at 4am every day is a good start. I do this too, and there's no discipline involved in going to bed - I just get very sleepy around 8 or 9 and want to go to bed.
I'm glad it works out for you (I actually mean that), but getting tired at 9:30pm every day would make me unhappy. I really want my free/"me" time do be after everything I have to do is done.
Haha .. I thought I was unique in waking up early/feeling asleep early. Guess I have good company. Ritual for me is tip toeing to the basement to avoid waking up the kids and grabbing some caffeine. Biggest challenges are distractions - news, youtube, and hacker news. I need to get better at just focusing on code and not going off on tangents.
What I have found to be helpful is that sites that I might find myself wasting time - Twitter, Reddit, etc. - I block these sites via the `hosts` file. I do this on the machines on which I want to find myself productive.
On my whatever laptop - the Internet is fair game.
I've done this sort of schedule quite a lot since my first kid was born (nearly 2 years ago). We share a bedroom, and they sleep a lot easier when I'm there too - often I just go to take them to bed, and end up falling asleep too at 9pm :D
I will wake up and let my brain wonder, then get up after 15 mins or so. By that time I'm wide enough awake to start coding straight away and know what I want to accomplish in the time I have. I don't check my phone at all in this time, as that'll lead to spending two hours down a rabbit hole on Reddit.
> do you immediately start coding? What is the morning ritual?
I wake up, get dressed in the dark, and go downstairs where I immediately start coding. I leave all the lights off and focus solely on my task at hand, and I typically use a todo list in bear.app to know immediately what to work on.
Breakfast comes at 6:30am when house wakes up. Since I'm WFH for day job I can shower do morning routine before work, which usually starts around 8am.
Well that cat is firmly out of the bag by now. You can find a less stressful work environment though, you just need to get rid of the attitude that a strong work ethic is good for you. It’s good for your employer.
We are starting to reflect the way we have organised the world in technology. Everything about life used to be fuzzy but now it's hard lines and definitions. It's going to do strange things to human culture.
Your workouts aren’t that strenuous. So you don’t need rest and recovery. If you are pushing past your limits, you won’t even have the desire to code in the evenings.
I exercise 5 days a week for 30 minutes right after my day job ends. I'm WFH so and have weights and stationary bike in my office, so it's easy to jump onto.
How long have you been doing this for? Because people do get used to things like that over time. My girlfriend usually sleeps right through me getting up at night.
I’ve been asking people this question. But first some context.
Push-ups are almost universal in fitness tests. They are a solid proxy for strength. Additionally, they are an exercise that is manageable enough that you can do daily and reap significant returns if you do them consistently.
What are the push-ups of programming? More specifically for me, c++.
I hate to be one of those guys ("well actually, your question is wrong, because ...") but I spent a lot of time trying to find "C++ pushups" before deciding that I may as well work on interesting projects and try to consciously improve my C++ while doing them.
I mean, sure, you can do Project Euler (or many other things), but you can also work on cool projects. I'm writing a superoptimizer (and I have C++ coding stuff at work). For both, I make a conscious effort to try to figure out better ways of doing that stuff (rather than just banging out ancient idiomatic C++ that isn't modern or good) - it's easy to slip into "doing things a dumb but quick way" that doesn't teach you much about the language or coding.
I have a similar attitude to push-ups, honestly. I'd rather bench press once a week and do a sport than be constantly banging out push-ups. In both things, you quickly get to the point where you're hitting diminishing returns from the "push-up" type of operation, unless your goal is "to be the best at exercising".
If we're comparing someone who couldn't complete 10 pushups or do a basic Project Euler problem with someone who can, I'd say "sure, that first person needs pushups (or programming equivalent)". I'm not sure once you're well beyond that point whether it makes sense to do that many more "pushups", unless you are going to a push-up competition in a month's time.
I think the sentiment is good. Who wants to waste time on “exercises” for programming? It’s much more fun to make stuff. The field is so vast and deep that you can pursue anything that interests you and learn a lot.
Came here to say that programming exercises (hackerrank, etc) seem completely redundant when you can spend the time creating something useful whilst also improving your programming skills.
This is an interesting analogy and question. I'm a fitness guy and you're right, things like push-ups or squats are a vital, great thing to do regularly.
I don't think performing a specific exercise is the route here. It's probably best to work backwards and find projects/challenges you find interesting and implement them in c++. You'll inevitably build new muscles + strengthen existing ones and most critically, be motivated to do it.
Two fitness principles:
- Specific Adaptation to Imposed Demands (SAID)
- Training blocks / periods / cycles / waves
What are you trying to accomplish with C++?
If you’re looking to have a better command of syntax, then do advent of code or something aimed at that. If you’re trying to implement algorithms in C++, get an algorithms book and implement them in C++. If you’re trying to get better at designing and architecting C++ code, look at good implementations (easier said than to find).
What ever you practice, that’s what will improve, so it’s best to align that with your goals and work backwards.
Athletes tend to have different phases of their training. Some periods of pre-season training, season, post-season where there may be a greater emphasis on things like strength, endurance, power.
I think building is good, but there must be some other phases too. You can’t just build all year or else you might get stuck in a local maxima. So, there should be phases of learning, building, refining. Again, aligned with what your end goal is.
Push-ups is taking time to understand fundamental constructs. Everytime you are surprised by the language, take the time to understand why it behaves that way. Making this into a habit will grow your knowledge and give you core strength so to speak :) You will be able to progress from trial and error into diagnosing and correcting problems.
I don't think the analogy works so well ... programming and exercise are very different.
Once you're not a beginner, programming mostly becomes about the specific domain youre working on, rather than the code. So improvement comes from a better understanding of banking or file systems or whatever you're doing, rather than cross-training in some proxy thing the way you do with exercise.
I had a coworker like that. He had 4 kids, stayed late in the office (as did I). When we would meet next day, he'd tell me the stuff he did with the kids before bedtime and some amazing piece of code he wrote or that book on programming he read. I just don't understand it. I live and breath tech but in my 40s, I need a caffeine IV to stay awake past 10pm. I do wake up early (5:30-6) and am totally clear headed then (with the caffeine IV/jk). I just can't do nights anymore. Anyone found a hack?
40 yo here. I get up at 5 and go into work immediately. Generally try to be in bed by 10ish. I've cut down the caffeine to about half a cup in the a.m., and that seems to help quite a bit with mid/late day energy.
Maybe try a biphasic sleep pattern. It's just a fancy way of recommending an afternoon nap but it might really help you stay energetic for the second half of the day.
There's nothing wrong with getting 8 hours of sleep / night! I'm not 40 yet but I learned early on that I need sleep or I can't function. The actual time of day shifts around over the years, but getting 8 hours is important for me.
Every time I read about one of these projects, I am at once SUPER THANKFUL for the time that this person puts in, to improve a project that I depend upon daily, but also somewhat incensed that there are thousands of large corporations that have a dependency on this stuff that they aren't giving back any support for.
> but also somewhat incensed that there are thousands of large corporations that have a dependency on this stuff that they aren't giving back any support for.
Usually, this is due to decisions the author made, and the author is in full control of changing the situation.
I come from a society where it's normal for people to give stuff with no strings attached, and then later claim I have a moral obligation to pay back for all the benefits I received. It sucked being in that society.
Really honestly shocked that I got down-voted on this.
Is it really not cool to wish that developers would get compensated for their time if their work is valuable?
I understand that the developer chose the license and distribution model, but if they hadn't chosen this model, then the community would have settled on whatever the best solution was that was permissive enough that they didn't have to pay for it. Passion projects in OS are a race to the bottom compensation-wise, due to dynamics outside of the control of the developers building them.
Imagine what society would look like if we had a basic income and someone like this could work on projects like that without having to worry about the commercial implications of their work. There's no reason we can't live that way now except that we choose not to.
We find it preferable to live in a society where a handful of people can accumulate billions of dollars. Dollars which have been extracted from the labor of others and influenced by the duress of losing food and shelter.
I have a similar schedule for a portion of my work.
I find that I have 2 really good productive hours right before bed. I also find 3pm-5pm to be extremely unproductive for me. So my schedule is usually 7am-10am work, 10am-12pm exercise, 12pm-3pm work, 3pm-7pm dinner/family time, 8pm-10pm work.
This type of schedule feels very liberating to me. I don’t feel like I’m working that much, but when you add it up it’s quite a few productive hours in a day.
What was striking was just how happy and energetic he seemed to be. Really nice guy. That he spends so much time in front of the computer is quite a shock for me.
Because when I do it I become a nervous wreck when doing hobby projects, always looking for “more programming time” (like an addict), and without energy for anything else. So even though I like coding a lot, I just become the opposite: unenergetic and not that happy.
He has solved the puzzle somehow, it’s impressive.
179 comments
[ 3.2 ms ] story [ 137 ms ] threadPersonally, I find I sometimes have trouble accepting good enough solutions. I want more structure, a better defined start. At night I can drop into a productive flow state with much less resistance, ignore many of the day-time wants. The hours run short; let's seize what we can from the waking hours. As well that "inspiration," I think there is probably a physiological barrier lowering that happens as we go into the night. As we recede from the gods' light, as it were.
But the screwed up sleep cycles from years and years of this are starting to take their toll, so I've been trying everything I can to replicate that peace of mind during daylight hours. No silver bullet yet.
It's a different world and definitely has advantages. However, like you, I'm not sure it's worth the tradeoff of being horribly tired long before my usual bedtime.
In total, I think I still prefer getting up late and sleeping late.
If people are up, I can’t lock in; there’s a constant distraction somewhere in my mind.
If I’m the only person awake in the house, I seem to hit flow state with ease.
There's less local news. There's nobody to call or text. There are no deliveries. Slack is quiet. My email is quiet. Our repos are quiet. The dev logs are quiet. My family is asleep so I know they're good. If I need a minute to think, I can sit on my front porch and not worry about being distracted.
Now that I have a young kid, it's really hard (and generally selfish) to work those hours. I miss it.
It's probably frowned upon in some places, but when I _really_ need to focus (during daytime hours), I generally shut down slack, email, my phone, etc.
Generally, the teams I've worked with over the years have been amenable to this. I try to promote it with my teams as well: actual time off (no popping in while on vacation or sick), good sleep, time for focus, shutting off slack - especially when not working.
The last thing any of us need is to burn out because of notification overload. It makes us a stronger team if we're all healthy, well-rested, and able to get things done.
It's so bad that I've started to get anxiety every time I open my computer. I start to panic because I know a distraction is coming. It makes it so difficult.
* https://stackoverflow.blog/2020/08/03/getting-started-with-c... * https://www.firsttimersonly.com/ * https://opensource.guide/how-to-contribute/ * https://github.com/MunGell/awesome-for-beginners
I find it's really helped my mental health, especially when work can be a bit frustrating (in entirely normal ways)
Additionally doing that for 23 years, you can get done a lot of work.
Maybe waking up was a segfault
However, they are downright tortuous if they come as fever dreams (though fever dreams are of course unpleasant no matter what the subject, and are often hard to willingly wake up from, since you're having a fever).
It's good to be aware of what type you are and what works for you. Conversely, recommending anyone just gets up earlier may be more harmful than helpful, depending on the person.
Every once in a while I’ll try to code something. I’m able to get by if I want. I get bored with it quick though and it doesn’t bring me the same kind of flow buzz mental stimulation it used to.
I’ve gotta say though, the modern web wtf happened?
It’s only really for citations, not ‘scare quotes’.
Their closing quotes look inverted though.
https://en.wikipedia.org/wiki/Quotation_mark#German
As others already said, the French actually use the guillemets with thin spaces but the Swiss use them without.
But the outward pointing of the guillemets looks really odd to me. I like that the inward pointing guillemets basically scream "look at me, I'm a quoted part!".
I didn't know there was “ AND ”. I hate those fancy/smart quotes. They are not internationally understood and confuse computers and people alike. Just like I wish we would all just speak English, I wish we would all just use """".
Or do you mean the characters? Yes, I am indeed living in the German area and software here often uses those stupid, stupid "smart quotes". I believe we are also taught to write like that on paper. One opens, one closes the quoted phrase. Though I have no idea how this happened here, as right now, in Chrome, I can only produce "normal" quotes. """"
I need a good 2-3 hours away from the problem before my brain relaxes and I can actually talk without sounding like I'm stoned or mildly autistic.
This will invariably affect my sleep with either no sleep at all for 1-2 hours or dreams of fixing an issue over and over again resulting in me being less rested the next day.
I'd love for there to be a quick way to 'snap' out of programming mode but after over a decade of programming I haven't really found one (except for having a couple of pints...).
I’ve come to terms that, for me, hacking into the night, dreaming about solutions, then waking up and implementing them... is manic and deeply unhealthy.
Before I was fully aware of it, I’d get super disheartened, sleep on it, then come in the next day and nail it by 10.
That’s another thing: if something becomes comical, there’s usually a pattern. If it’s the positive kind of comical, repeat the pattern. If negative, consciously avoid (but that appears comically harder).
I m in a phase where the code at work interests me so much that I think I sleep 5 hours a day, the rest I touch that code. Non stop, and I have a kid.
Thank god it s usually just a phase :D
I've found that giving myself a solid hour to wind down helps immensely with slowing my brain down and letting me sleep more peacefully. Sometimes I read, or listen to music, or watch youtube, or have a beer or an edible and just hang with out, or just tidy the house or something. Whatever it is, it's not work, it's not in my office, and it's not hard. I've found I've been sleeping far better because of it.
Even on nights that I work super late on some head scratcher, with a full 12-15 hours at my desk, I still give myself the hour before going to bed.
If my mind is really stimulated, this may feel a bit awkward initially, forcing my mind to "calm down and focus on the video", but at the end of the hour it's usually fine.
And then do not start thinking about a related problem again when you shut the iPad off. I made that mistake so many times.
For me this formula works like magic because I can't control my mind from constantly iterating when starting new projects so I use this as a chemical brake.
This made me always get the right amount of sleep no matter what.
This is why flexible/remote work time is good. If you need to go late you can but you won’t be punished for it by a 9am standup.
"Getting off the ground" is for me, a great big open-ended architectural decision making process with an ocean of second-guessing myself. It's very very likely to keep me awake for hours reevaluating everything I did in that last couple of hours.
Smaller pieces of work are different. Actually fixing a bug has a fairly well defined "ending" and I can sleep easy basking in the warm glow of satisfaction. Even getting part way through implementing a feature is a thing that doesn't put my brain into "wide open exploration of all possibilities" mode. It's maybe not so easy to bask in achievement and sleep as a quick bug fix, but at least the "code dancing in my head" is a fairly narrow path of implementation I've probably already got the structural problems solved for.
For me - starting projects need empty weekends.
> we add features, improvements and bug-fixes continuously. With 240 command line options , 26 transfer protocols and countless combinations of things done over a crazy Internet that's just the nature of it all...
I could see creating quality implementations of each of those taking that long.
https://curl.se/
A sensible plugin architecture would let you do either
or a naming convention would load the appropriate plugin based on the protocol.Yes I know, armchair code design. And I also know it's nice not to have to deal with configuration, a large app "just works" (though FYI, it does have 15-20 dependencies which are similar to plugins, it has 3 direct and more indirect dependencies). But, 2hrs a day * 23years = 16790hrs!!!!! Something seems wrong for that much time to be spent on "curl"
Just to be clear, first, thanks so much for curl! And second, of course having not touched the code ever I have no idea why it required 16k hours of dev time and continues to require more, it could totally be justified.
I'm only saying that at a glance, 2hrs a day, 23years sounds surprising and it makes me wonder if there isn't some ways to reduce the load.
You seem to be conflating curl as only an app that deals with http/https. Curl really does a lot more.
Curl has 170k lines of code, so it's bound to require some maintenance.
I'd imagine manual laborers sleep much more soundly, and are less likely to code in their down time. (but maybe!)
I’m guessing most our our personal metrics for what makes software “good” are only somewhat aligned with capital.
[0] https://medium.com/@hfuecks/so-we-went-with-a-hamburger-menu...
Why waste those precious 'awake' hours on code when I can be enjoying my family?
IMO your comment is even more inspiring than the thread itself :)
For me, 7 kids was the point at which I could no longer effectively maintain procps.
I had to adjust my bedtime to accommodate waking up so early. I'm fairly disciplined about it and never stay awake past 9:30pm.
The reason I chose morning instead of evening is I'm pretty tired after work to do anything. And so I get to dedicate my evenings to family time.
Edit: typos.
So, 6.5 hours of sleep though? I need either 7 or 9, but 8 does not work for me.
So, I would be looking at 5a.
Let me ask you, do you immediately start coding, or do you need a few minutes to ‘warm up’?
What is the morning ritual, if you don’t mind me asking?
On my whatever laptop - the Internet is fair game.
I will wake up and let my brain wonder, then get up after 15 mins or so. By that time I'm wide enough awake to start coding straight away and know what I want to accomplish in the time I have. I don't check my phone at all in this time, as that'll lead to spending two hours down a rabbit hole on Reddit.
I wake up, get dressed in the dark, and go downstairs where I immediately start coding. I leave all the lights off and focus solely on my task at hand, and I typically use a todo list in bear.app to know immediately what to work on.
Breakfast comes at 6:30am when house wakes up. Since I'm WFH for day job I can shower do morning routine before work, which usually starts around 8am.
edit: typo
Modern life is just so depressing, we have so little free time. Everything must be scheduled, compartmentalized, etc
I usually do some programming when the kids and partner have gone to bed but I also do some exercise at lunch together with my partner.
Push-ups are almost universal in fitness tests. They are a solid proxy for strength. Additionally, they are an exercise that is manageable enough that you can do daily and reap significant returns if you do them consistently.
What are the push-ups of programming? More specifically for me, c++.
https://projecteuler.net
I mean, sure, you can do Project Euler (or many other things), but you can also work on cool projects. I'm writing a superoptimizer (and I have C++ coding stuff at work). For both, I make a conscious effort to try to figure out better ways of doing that stuff (rather than just banging out ancient idiomatic C++ that isn't modern or good) - it's easy to slip into "doing things a dumb but quick way" that doesn't teach you much about the language or coding.
I have a similar attitude to push-ups, honestly. I'd rather bench press once a week and do a sport than be constantly banging out push-ups. In both things, you quickly get to the point where you're hitting diminishing returns from the "push-up" type of operation, unless your goal is "to be the best at exercising".
If we're comparing someone who couldn't complete 10 pushups or do a basic Project Euler problem with someone who can, I'd say "sure, that first person needs pushups (or programming equivalent)". I'm not sure once you're well beyond that point whether it makes sense to do that many more "pushups", unless you are going to a push-up competition in a month's time.
I don't think performing a specific exercise is the route here. It's probably best to work backwards and find projects/challenges you find interesting and implement them in c++. You'll inevitably build new muscles + strengthen existing ones and most critically, be motivated to do it.
What are you trying to accomplish with C++?
If you’re looking to have a better command of syntax, then do advent of code or something aimed at that. If you’re trying to implement algorithms in C++, get an algorithms book and implement them in C++. If you’re trying to get better at designing and architecting C++ code, look at good implementations (easier said than to find).
What ever you practice, that’s what will improve, so it’s best to align that with your goals and work backwards.
Athletes tend to have different phases of their training. Some periods of pre-season training, season, post-season where there may be a greater emphasis on things like strength, endurance, power.
I think building is good, but there must be some other phases too. You can’t just build all year or else you might get stuck in a local maxima. So, there should be phases of learning, building, refining. Again, aligned with what your end goal is.
Once you're not a beginner, programming mostly becomes about the specific domain youre working on, rather than the code. So improvement comes from a better understanding of banking or file systems or whatever you're doing, rather than cross-training in some proxy thing the way you do with exercise.
A sincere 'thank you' for curl.
Every time I read about one of these projects, I am at once SUPER THANKFUL for the time that this person puts in, to improve a project that I depend upon daily, but also somewhat incensed that there are thousands of large corporations that have a dependency on this stuff that they aren't giving back any support for.
link rel: https://curl.se/donation.html
I am not a Curl contributor, or related to the project, but I do donate.
Usually, this is due to decisions the author made, and the author is in full control of changing the situation.
I come from a society where it's normal for people to give stuff with no strings attached, and then later claim I have a moral obligation to pay back for all the benefits I received. It sucked being in that society.
Scientology? China?
Is it really not cool to wish that developers would get compensated for their time if their work is valuable?
I understand that the developer chose the license and distribution model, but if they hadn't chosen this model, then the community would have settled on whatever the best solution was that was permissive enough that they didn't have to pay for it. Passion projects in OS are a race to the bottom compensation-wise, due to dynamics outside of the control of the developers building them.
We find it preferable to live in a society where a handful of people can accumulate billions of dollars. Dollars which have been extracted from the labor of others and influenced by the duress of losing food and shelter.
Just the warm up to my builds take 2 hours :(
I find that I have 2 really good productive hours right before bed. I also find 3pm-5pm to be extremely unproductive for me. So my schedule is usually 7am-10am work, 10am-12pm exercise, 12pm-3pm work, 3pm-7pm dinner/family time, 8pm-10pm work.
This type of schedule feels very liberating to me. I don’t feel like I’m working that much, but when you add it up it’s quite a few productive hours in a day.
What was striking was just how happy and energetic he seemed to be. Really nice guy. That he spends so much time in front of the computer is quite a shock for me.
Because when I do it I become a nervous wreck when doing hobby projects, always looking for “more programming time” (like an addict), and without energy for anything else. So even though I like coding a lot, I just become the opposite: unenergetic and not that happy.
He has solved the puzzle somehow, it’s impressive.