How to Flow Into the Zone

One of the most beautiful moments when writing code is when you are totally focused and flow in the zone.

When you have a clearly defined task and know exactly how to solve it, you are able to get sucked into your code and forget everything else in the world.

You may experience moments of greatest peace. Mihaly Csikszentmihalyi in his book Flow: The Psychology of Optimal Experience even describes this state as absolute happiness. And he’s right. When you’re wired in you think about nothing but your code. There exists no past and future, you don’t worry about any unimportant stuff and just totally live in the moment. That’s where happiness can evolve.

But how do you achieve such a state?

Apart from clearly defined tasks and the right distraction-free environment, there are simple techniques that help you to get into the zone.

Headphones

Obviously, many of us coders wear headphones when they are at work. I always have to smile when new interns ask if they are allowed to listen to music or when I remember asking this question myself in the past.

For me, putting headphones on and starting up my favorite playlist or latest mix on YouTube is the best way to start getting concentrated and achieve the state of total flow.

But it doesn’t have to be music at all. Another great way to stop distractions by your surroundings is nature sounds. Often seen at screens of my coworkers and also used by myself. You can look up sounds for thunder, rain, forest, sea etc. on YouTube or use apps like calm.com.

Find the tunes that suit you best and start coding. Every person is different. After a few minutes, you may feel how your code teleports you into another world.

I had the best experience with electronic sounds without any vocals, like deadmau5 for instance.

And then I pray for you that no coworker comes around the corner and asks you if you have received his latest email.

By the way, if you’re just starting out with this technique, don’t care too much about what kind of headphones to use. You don’t need those fancy high-end noise-canceling headphones when you’re also getting pretty sweet sound from a pair for 15 bucks. Or you simply use the ones provided with your smartphone.

Pomodoro

Alright, when your gear is set up and you know what to do, don’t do it for eight hours straight without any breaks.

A better way to organize your work might be the so-called Pomodoro Technique. Pomodoro is Italian for tomato and is called that way because Francesco Cirillo – the creator of this technique – used a tomato-shaped kitchen timer.

But why do you need a kitchen timer?

In essence, the idea of the Pomodoro Technique is that you chunk your tasks down in small packs that take 25 minutes each. When the 25 minutes are up, you have a 5-minute break and then move on to your next 25-minute pack.

In my experience, that’s easier said than done. But with the right adjustments, it’s totally worth a try.

The biggest problem for me are those 25 minutes. It’s not always possible to chunk tasks down and finish them in almost half an hour. Sometimes I’m faster, sometimes it just takes longer. Sometimes you get distracted by anything or your boss comes around and you have to stop, no matter what.

So, even when the theory sounds great, the Pomodoro Technique really is not that easy to implement in the office. Still, I just try to work for 25 minutes on my next task (no matter how big or small it seems to be) and only focus on that single task.

If there are any external interruptions, well, I can’t always avoid these. But I can try to be disciplined and at least stop any interruptions done by myself. You know, things like reading posts on dev.to for instance.

A great tool to try the Pomodoro Technique and that I use is kanbanflow.com. There you can add your tasks, start the timer and even track the complete time you used to finish your tasks. Makes things easier and also pretty interesting.

Fresh mind

Okay, so we have the music, we have our 25-minute task packages, what’s next?

Quite simple actually: Keep your mind and body fresh. No music and no productivity technique helps when your body is crying for sleep or something to eat.

As mentioned in the article 3 Healthy Habits for Programmers, a healthy body and mind is the perfect foundation to conquer your everyday tasks as a software developer.

Keep your body hydrated, do some exercise and never underestimated the power of sleep.

If you take these little things into account, you’re ready for any project ahead of you.