I've often wondered this and experimented myself with meditation from time to time. I do have a little ritual I do before I start coding that helps me reach <i>the zone</i>, that is basically a small meditation:<p>1. I close my eyes and try to think of nothing except what I'm about to do.
2. I focus on my breathing.
3. I envision myself coding with everything going smoothly, I'm in the zone.<p>I do this for a few minutes and try to maintain my focus, seeing myself coding with a big smile on my face. Then I get to work. It helps on days where distractions are especially tough and my mind seems like a huge mess.