Hacker News new | past | comments | ask | show | jobs | submit login
Coding As A Substitute For Meditation? (statspotting.com)
20 points by npguy on Dec 2, 2012 | hide | past | favorite | 22 comments



To be fair - there's a massive different between focusing on something you're passinate about (like coding) and focusing on not thinking. Not thinking and letting your mind relax is completely different from, and often way harder than, thinking about a passion.

Jusy "getting in the flow" is not the point of most meditation.


Please keep in mind that the flavour of meditation you are describing is not the only one.

"[M]editation refers to a family of self-regulation practices that focus on training attention and awareness in order to bring mental processes under greater voluntary control and thereby foster general mental well-being and development and/or specific capacities such as calm, clarity, and concentration" Walsh & Shapiro (2006)

"[M]editation is used to describe practices that self-regulate the body and mind, thereby affecting mental events by engaging a specific attentional set.... regulation of attention is the central commonality across the many divergent methods" Cahn & Polich (2006)

The practice of 'coding in the zone' might as well achieve the same effect as traditional meditational practices and be called meditation on that ground. In fact, you are training the control of your attention with that practice.


I have similar deep experiences doing meditation related practices (Pranayama) and programming. This happened when I was focused on solving a single algorithm for long time. If I have to describe details about this time I can say that I was 18 years old, was doing my own parsing algorithms for a small language, and I debugged the algorithm in my head all the time.


I'd agree for the most part. If it helps the person relax and promotes concentration, then that's good. And the more naturally it comes the better.

A lot of meditation in western countries consists of people forcing themselves to sit and focus, then measuring the amount of time they sat as an accomplishment. It doesn't lead to any long term benefit though, and if really forced, it will actually have the opposite affect.

EDIT: Actually beneficial mediation is something else, and the Tibetan traditions flat out understand it better than anyone, period, they're the Caltech or MIT. Other traditions are ok, but they're not the same caliber.


I think it's more convincing if you point out that the reason meditation is harder is the effort involved in pointing your thoughts back towards your breath or something else very simple.

Flow is the state where it is no longer a struggle to control your attention. What you are paying attention to can require a very active mind.

Mindfulness meditation involves practice at directing your attention, your focus is on meta-cognition. Your breath is often chosen because it requires no attention. It's boring. That makes it good practice at discarding all the other thoughts that come up and focusing your attention back where you want it to be.

Sure, meditation is a broad term but this is at the core of the vast majority of what's called meditation.

Some ideas involve meditation with a goal (considered attainable or just an asymptotic ideal at the end of the direction of improvement) of achieving a state like flow in this practice, so you no longer struggle to maintain your attention on nothing. Apparently extremely serene and calm and peaceful. Sounds wonderful.

Flow is different from meditation, to paraphrase what ramblerman said in another comment: meditation is an exercise of directing attention. Being good at that can help you attain "flow" more easily in other activities.

I know I've found meditation to seem to be good practice for when I want to focus my attention deeply.


Exceptionally misguided. Having meditated for an average of forty minutes every day (sometimes for as much as 2 hours a day, in 40 minute blocks) for the last half year and having coded many, many hours in my life, I can say that this conclusion is decidedly incorrect. Most forms of meditation are about doing nothing except breathing. Coding, like any other task, is far from this. Again, exceedingly misguided.


Exceptionally misguided.

Indeed, I would even say such misconceptions are harmful, since coding has quite the opposite effect. After a day of too much or too intensive coding, I usually find that my brain continues to be occupied with coding problems. E.g. when I'm half-sleeping I see problems that don't exist (at least not in sleeping ;)). Meditation has the opposite effect: the mind becomes calm and unoccupied.

It's important to give the mind rest and time to process your day.


I agree, I think the original post is harmful because the author suggests an activity that will strengthen identification & thereby increase suffering. Meditation does the opposite, in my experience, anyhow.


Why not do both until you understand the real differences?

The reason people voluntarily stay up late to code, while meditation by contrast seems kind of boring — the reason why people are so eager to come up with different "substitutes" for meditation that just so happen to align with their favorite things to do — is very near the essence of why meditation probably shouldn't be replaced by coding, or running, skiing, drinking, smoking, or whatever your favorite activity is.


Meditation is not about cluttering your consciousness, but freeing it from agitations and useless load, we produce themselves.

It is not about chanting mantras. It is about realization of the "source" of the mental content.)

Calling a concentration, deep focus of so-called state of flow a meditation is confusing misuse of the language (using wrong associations).

Constant agitation and restricted, repetitive patterns of "thinking" is misuse of the mind.)


No. What you described is called flow.

There is a good chance however that practicing meditation will help you find more 'flow' in your activities.


I'm not a Buddhist, but I have attended a few classes on medetation. I had a bit of an epiphany at one session. Portions of the experience of meditation are similar to being "in the zone" when coding. A lot of other commenters here have already mentioned it: "flow".

There is a significant difference though. When you are coding, you experience flow with your mind already full of things. When meditating, you start with an empty mind, so the perceptive influence of flow is far more noticable. It's enough to throw you out of the meditative state if you are unprepared.

The goal of meditation is different than that of coding as well. Meditation starts from an empty mind so that you once you reach a meditative state, you may choose to do any number of things. One exercise the instructor had us perform was to find a meditative state, then meditate on the first thought that entered our mind, and to not sway from that thought.

When you're coding, you are keeping many things in mind. I find that when you end up in the "flow", it is because you have pushed everything out of your mind as a result of there being no space for it. Meditation is about pushing everything out of your mind so there is space for anything.


I'm kind of turned off by this post. I'm a fairly experienced meditator in a few Buddhist traditions. You could definitely make coding a kind of meditation. People do driving meditation, or dish washing meditation, but it's usually as an extension of other mindfulness practice. I wouldn't just slap the 'meditation' label on coding unless the practitioner is explicitly going out of his/her way to make it a meditation.


Commenter on the blog nailed it (“noise is a substitute for quiet”), or: activity as a substitute for inactivity, work as a substitute for rest.

In the Buddhist traditions meditation is used as a tool to examine the subtle nature of the mind's processes, how they may create suffering through craving, aversion & identification (dependant origination) which initially at least requires some down-time to bring the mind to a relatively quiet state. You really learn a lot about craving when all the goodies are taken away, similarly you learn about aversion from the small discomfort from sitting.

I love coding, it's my main intellectual outlet, but I never want to be someone who has to lug along a laptop on holiday because the pain of being away from code is too great, I take any such pain as indication that I'm broken in some way (addicted). If I simply coded every time I feel that addiction I'd never truly discover how dependant my happiness is on coding & I'd never discover that I can be happy without coding. I think coding is nicer when I'm not addicted to it.


Perhaps there are comparisons to be drawn between the two, but I think don't think they should be dependent on set amounts of time doing them: After an hour of coding something, I'm likely to either want to continue hacking on what I started, work on something else, or stop working entirely(rather than presumably continue working with a refreshed mental state..?).

Part of meditation is precisely /not/ doing or thinking about anything. As another comment pointed out, this is sort of finding a substitute for meditation in something most of us would likely being doing anyways, since the majority of us have trouble breaking out of our day-to-day cycle to literally sit for 15 minutes and do nothing whilst so much is going on regardless. I think there are similarities to be drawn in terms of "flow" or getting "in the zone" so to speak while writing code, though.


I don't think it's valid to compare a flow state with meditation. Coding isn't just "one thing", not like mindfulness mediation practices are about "one thing".

It seems to me that coding is about actively using a lot of your brain. At the abstraction level of a brain or a mind coding is a whole lot of different things.

I happen to think meditation is good practice for directing your attention mindfully, improve your ability to direct your thoughts. Good at directing your thoughts at something? You'll find you enter flow states when doing it. So I see the connection, but they aren't the same.


This is wrong on so many levels. Why is this on the front page?


I think you are mixing the feeling of achieving a state of flow with the goal of an activity.

There are many ways to reach a state of Flow , coding and meditating may get you there, but as practices I don't think they have more in common than skydiving, rock climbing or surfing a perfect wave..

Personally.. meditating for me is more is like a call to System.gc() on my brain.



Similarly, I've found that playing engrossing video games draws most of my attention from pain -- or anything else really.


Yes, when I was exhausted from coding or simply the stress of work playing an imersive video game helped to refresh my mind.

Also, years ago when I was studying and had headaches, playing chess against computer was also refreshing. I suppose I was using different parts of the brain and letting others rest.


This an observation well supported by the theory of Flow. It's psychology's foray into positive thinking, a big part of which is productivity.

Coding, when you're good at it and have mastered your tools, IS meditation (at least on the surface) as you feel an intrinsic sense of well-being.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: