Comment by RankingMember

Comment by RankingMember 2 days ago

21 replies

I'm very impressed by (and jealous of) anyone who can context switch fast enough to make use of 10 or 15 minutes here and there to do a completely different task (and actually have it be coherent).

munificent a day ago

I wrote both "Game Programming Patterns" and "Crafting Interpreters" largely in chunks around half an hour between work, parenting, and other life duties. Likewise lots and lots of hobby programming projects.

Context switching is a skill that gets easier the more you practice it, just like any other. There are techniques like leaving good notes to yourself to pick back up where you left off more easily, but a lot of it just mental training. You sort of learn to hold some of the context in your head all the time but keep it idle when you aren't using it.

When I'm hacking on a hobby programming project, I can often fix a bug or tweak a small feature in fifteen minutes, make a commit, and get a little serotonin hit, all while I'm waiting for the wife and kids to get ready to leave the house.

It doesn't always work for all kinds of tasks. Sometimes for more challenging stuff I really do need a larger chunk of time to load it all in my head. But you'd be surprised how easy it is to eat an elephant one tiny bite at a time if you really try.

  • mhaberl a day ago

    ..and the Wren compiler :)

    > Context switching is a skill that gets easier the more you practice it, just like any other.

    Totally agree with this!!

    I learned this when I started off as a junior dev. We had some shitty machines and the project compiled for like almost 10mins. Most of the people just read the news and stuff and for some reason I started reading Clean code from Bob Martin (probabbly someone sent me a pdf of it or something). I remember reading it all in a few weeks using those breaks. Then I just kept the habit for almost a year (until we got some better workstations).

ChicagoBoy11 2 days ago

I had a friend in college who was the ultimate expression of this. If he was in a line, waiting for someone, outside a professor's office hours, etc., he was working on SOMETHING, usually getting ahead of some reading for class. I asked him later, and he gave quite a compelling account of how if you truly added it all up, it had a pretty huge effect in how long it took him to get through his work. He was incredibly bright, went onto a PhD at MIT, and was also very sociable, which I suspect was helped by this strategy of aggressively seizing on these little breaks of time.

I need a good chunk of time to settle into "productive" work, even if it is just reading. I suspect that what is needed is a little bit more discipline at first and slowly it gets easier, but I just never had the ethic to stick to it, and because of this friend I don't even have the ability to claim any doubt as to how impactful it would be.

  • ekropotin 2 days ago

    Genetics also plays a significant role here. For example, one of the major symptoms of ADHD is inability to quickly shift into productive mindset.

    • itsoktocry 2 days ago

      What is a "productive mindset"? Why do we so easily dismiss some things as due to genetics, while for others it's strictly taboo?

    • hbarka a day ago

      Isn’t it the opposite? A common “superpower” observation for people with ADHD is they excel at rapid context switching and have an advantage with multitasking, like in crisis response, problem solving, or keeping track of multiple predators.

  • throw3982203 a day ago

    This is how I fight procrastination on certain tasks.

    For some reason, a forced time constraint based on external pressure motivates me enough to finish a task.

  • fragmede 2 days ago

    I doubt they were doing deep work in 3 minute chunks in line at the parking ticket office. One thing I realized for me is that simply priming the pump for later had non-zero benefits. Eg, doing a Google search for something, and just reading the result snippets counts for something in those 3 minutes. Reading the Wikipedia page on something isn't full actual proper research, but reading it five times (because you keep getting interrupted in the post office), but still managing to read it, counts as progress for later. Your brain simply just needs time to stew on things, hence the solution striking during a morning shower.

    • michaelhoney a day ago

      And much of a project, like life, isn’t deep work. It’s the thousand little things, things which are indeed doable in the interstices

dave78 2 days ago

I got much better at this when my kids were born, because it was the only way I could get work done on some of my (computing) side projects. I went from having hours of uninterrupted "in the zone" time during evenings and weekends to having much less time overall, and what time I did have was broken into smaller chunks.

I got much more thoughtful about how I used my time and also got better at pre-planning what I had to do so as to make the best use of it. Mostly the key was to just try to tackle smaller tasks and accept that progress would be slow.

  • cluoma a day ago

    That's been exactly my experience as well. Sometimes doing a little research on a lunch break gives enough direction on how to spend available time later on my project.

    Accepting that progress will be slow has been the most difficult adjustment, and applies to more than just side-projects. Choosing books or games also becomes a more strategic decision when what used to be a weekend sprint, turns into a several week marathon.

fhd2 a day ago

If you have an activity where you get to _think_ for hours about what you're gonna do, you can really do a lot in 15 minutes.

  • FrojoS 16 hours ago

    Exactly. I also assume that the author was “writing” his stories in the head, while doing construction. He then just had to quickly put it onto “paper” in his breaks.

rnoorda a day ago

I feel the same! One bit of advice has helped me take better advantage of those small chunks of time- "Park facing downhill." I don't remember where I first heard it, but the idea is to stop somewhere naturally conducive to resuming work. Start making the list, and stop at a point where it's really easy to write down the next few items. Or leave the really easy bit of code for next time.

I'm not good at it, because I prefer to cross things off when I finish them, but when I can pull it off it saves some of that time getting oriented to what I'm working on.

scandox 2 days ago

Yes I also cannot do this. I comfort myself by believing the nature of their work allows them some sort of meditation on what they will do in those little gaps...but they may just have an enviable power that I do not have.

dkarl 2 days ago

I'm great at this if the other task is routine. For example, if I'm cooking a dish I've made dozens of times, I can context-switch between that and difficult work. If I'm making a recipe I don't know by heart, context-switching to another task ruins my ability to think about either.

shermantanktop 2 days ago

I do this. The danger is that switching out is as easy as switching in. What one needs, in addition to the ability to refocus, is some actual discipline.