1. 31


“The Tetris effect (also known as Tetris syndrome) occurs when people devote so much time and attention to an activity that it begins to pattern their thoughts, mental images, and dreams”

    1. 41

      99% of debugging happens on the toilet.

      1. 20

        I’ve been doing this for decades, and I still often forget that the best thing to do when I hit a wall is to queue up some good music and take an hour long walk or bike ride.

    2. 34

      I had to stop coding right before going to bed because of this. Instead of falling asleep, my mind would start spinning incoherently, thinking in terms of programming constructs (loops, arrays, structs, etc.) about random or even undefined stuff, resulting in complete nonsense but mentally exhausting.

      1. 12

        I dreamt about 68k assembly once. Figured that probably wasn’t healthy.

        1. 4

          Only once? I might have gone off the deep end.

        2. 3

          Just be thankful it wasn’t x86 assembly!

          1. 4

            I said dream, not nightmare.

            1. 2

              Don’t you mean unreal mode?

              being chased by segment descriptors

              only got flat 24bit addresses, got to calculate the right segment bases and offsets, faster than the pursuer

      2. 7

        One of my most vivid dreams ever was once when I had a bad fever and dreamed about implementing Puyo Puyo as a derived mode of M-x tetris in Emacs Lisp.

        1. 21

          When I was especially sleep-deprived (and also on call) in the few months after my first daughter was born, I distinctly remember waking up to crying, absolutely convinced that I could solve the problem by scaling up another few instances behind the load balancer.

          1. 4

            Oh my god.

          2. 2

            Wow that’s exactly what tetris syndrome is about. Thanks for sharing!

      3. 5

        Even if I turn off all electronics two hours before bed, this still happens to me. My brain just won’t shut up.

        “What if I do it this way? What if I do it that way? What was the name of that one song? Oh, I could do it this other way! Bagels!”

      4. 5

        even undefined stuff

        Last thing you want when trying to go to sleep is for your whole brain to say “Undefined is not a function” and shut down completely

        1. 5

          Tony Hoare has a lot to answer for.

      5. 2

        Different but related: I’ve found out (the hard way) that I need to stop coding one hour before sleeping. If I go to bed less than one hour after coding, I spend the remaining of the said hour not being able to sleep.

      6. 1

        I know this all too well. Never heard of the tetris syndrome before. I need to investigate this now right before going to bed.

    3. 13

      Yes. For me the Tetris Effect is a clear sign of stress and an early warning of burnout. I’ve had to put boundaries up and create rules for myself like, “No coding before bed.” And when it happens, I know I need to pull back and and take some time off.

    4. 11

      So I once dreamed in Perl. I can’t even properly describe what that was like to anybody. I don’t typically remember my dreams but this one stuck with me for some reason. It wasn’t a dream about writing Perl code. It was as if I was evaluating Perl code to advance the storyline of the dream sequence. It was a very odd experience.

    5. 9

      Sound like some people in here are talking about unconsciously continuing to work inc a problem after hours:

      • “debugging happens on the toilet”
      • “stuck on a tough problem long enough”
      • “Taking time off on the bed”

      And others are talking about involuntarily imposing the patterns of software onto non-software things, productively or not:

      • “spinning incoherently, thinking in terms of programming constructs”
      • “parsing other people as structs”
      • “correlating politics and social structures with arquitectural problems in software”

      (I’m down for either or both conversations, Fwiw)

    6. 9

      I’ve experienced it years ago, in an intense period of C programming. I went out for a walk and my mind was parsing other people as structs.

      1. 19

        At least you weren’t treating them like objects.

        1. 2

          That’s true, I guess I’m not very object oriented.

    7. 6

      I want to paraphrase this thread, because this is important:

      • This is all normal. We’ve all felt it once or even much more often.
      • find something to turn the brain off. For some it’s meditation, cardio, music, socializing. doesn’t matter find something that works.
      • Your work’s output is better when you are rested.
      • No matter how much you give, the company can always ask for more.
      • set boundaries to protect yourself.

      stay (mentally) safe :)

    8. 6

      Not from programming but a younger me communicated so much using a computer that instead of a voice in my head, I’d imagine myself typing my thoughts out on a keyboard.

      1. 2

        I still do this.

    9. 4

      If I’m stuck on a tough problem long enough, absolutely. I’ve woken up in the middle of the night dreaming up solutions to these problems before. Sometimes they’re complete nonsense; sometimes they’re actually useful.

    10. 3

      I have a very hard time with this. It can be very disturbing. I try to sleep but my mind stays awake in a somewhat incoherent thought line that vaguely resembles programming and problem solving. Most of it is nonsensical

    11. 3

      All the time. Frequently when I’m backpacking outdoors the code I’m working on invades my dreams. I don’t mind it, it motivates me to get to it when I get off the trail.

      1. 1

        I frequently experience insights when backpacking, or even day hiking. Its really nice to let my mind wander when I am going along a trail.

    12. 3

      I’ve played a lot of Tetris and every time I do my minds eye pictures colorful blocks falling and assembling to clear lines, solving t-spins, testing different sequences and possibilities and what not. I assume that picturing the blocks happens because the game is so colorful with easily distinguishable shapes.

      Programming has fewer visually distinguishable characteristics for me. The visual part of the programming in the background faded after a year or so. The worst of it happened when I was using msn messenger and starting typing std::cout <<. Now it’s just my mind constantly churning through ideas which I know on a conceptual level how to implement. No more blocks but the feeling of trying to shove a square into an appropriately sized and shaped hole remains.

    13. 2

      When I did a lot of work on certificate signing I had a dream about people as streams of hashes of some seed and their experiences through life. It was a really cool experience because it makes sense on some level. Also the streams in space with children forking off at various points looked pretty. Still probably the best dream I’ve had.

    14. 2

      This is generally how I wake up. It is not my favourite thing at 4am when you need to go to the bathroom but then can’t return to sleep.

    15. 2

      Yes it happened to me. I dreamed of programming, but no breakthrough came out of it. Taking time off on the bed helps to solve problems, tho. I still can’t program myself outside bad habits, but I setup an interrupt signal in my brain for when to go to look when coffee is ready!

    16. 2

      I’ve absolutely done this, in both programming and board games.

      It makes interacting with humans much much harder, but much easier to devise a software solution to a real world problem.

    17. 2

      I’ve seen myself looking at nowhere and correlating politics and social structures with arquitectural problems in software and how fixing one could translate to the other.

      Or seeing how other mundane stuff translates to a technical concept just because it’s called similarly.

      Can’t come up with an example, but 100% this thing happens to me a lot.

    18. 2

      Not really, even though I do program a lot.

    19. 1

      Quite frequently with great variety of things, wonder how much this relates to my hyperfocus/adhd.

    20. 1

      I don’t know about Tetris, but at some point I played so much Solitaire that I was seeing and playing Solitaire in my head when I closed my eyes.

    21. 1

      I got this when I learned Forth and when I learned hygienic macros. Also when learning Calculus and Linear Algebra.

    22. 1

      Thinking about software/system architecture of any random project, real or not, is one of the surest ways to get me to fall asleep.

    23. 1

      I have certainly gone through code dreaming, and fixed it the next morning according to findings. These happened a couple of times, and I’m still baffled by how little bits of large code bases seene to be able to stick around somewhere. I certainly wouldn’t have been able to recite code and even dreaming it was like I had to look whether that’s actually what was happening. Haven’t had that in a long time though. Probably for the better.

      But I don’t think that’s what Tetris effect/syndrome is about. Reading the article it seems to be about applying thought patterns to other things. Maybe for programming that would be more like seeing the work at a restaurant or store as an algorithm, thinking about daily chores that need to be done as conditions and executing then as functions.

      Something I’ve certainly done is at a time I work wise mostly had concurrency and parallelism in my mind, I was overly worried with doing things concurrently in an effective manner, using up all the time that would be idle wait.

      I only stopped that when I realized your brain isn’t usually idle waiting and during “relaxation” a lot of important stuff is going on, which either is maintainance but also sparking creative processes, etc. which seems more worthwhile than many other things that could be achieved by using up that time. I think it also helps to be more focused.

    24. 1

      Occasionally this will happen from coding, but my most recent episode of this was from playing too much AoE2. I would close my eyes and see an endless tiled map of town centers / villagers working on farms.