8 Habits to be a better programmer

Abdallah Yashir
4 min readSep 6, 2018

Programming is a creative job that requires lots of concentration, time and mental effort. Good software developers depend on habit instead of willpower to be consistently productive.


Understand the why

List down and make it a habit to revisit once per week the reasons why you have chosen to be a programmer. Motivation primarily comes from being connected to your purpose.

  • A good salary
  • Solving interesting problems
  • Having an impact on society
  • Helping your community with the use of IT
  • Good working perks
  • You get to work in a closed office with AC instead of facing the harshness of the outside world
  • With some companies you can even work remote, thereby avoiding traffic congestion
  • You don’t need to work on the weekends
  • You don’t need to stand on your feet the whole day
  • You don’t need to work at night

According to recent studies, willpower is directly connected to motivation. If you are not motivated to work, using willpower will bring it to depletion which makes it harder for you to even focus on trivial matters.

Get enough sleep

Sleep deprivation directly affects decision making and countless disasters in history has been attributed to it. It impairs decision making, competes for distraction and effective communication.
People with lack of sleep cannot focus for long hours in order to work on complex problems. They get easily irritable that can affect their relationships with others.
Sleep is essential for the body to function properly and is significant for happiness. A happy developer is a productive one.

Sunlight & Nature

Get some sunlight everyday

A study done to analysed therapeutic distress by psychologist Mark E. Beecher found that seasonal increases in the amount of time spent in the sun were linked to decreased emotional stress. Direct sunlight correlates with happiness.
As programmers, we spend too much time in the office with artificial lighting and constant stress. This affects our general well being including sleep cycles, emotional and physical states.
To be a happy and productive software developer, emotional and physical well being are important, they are boosted by enough exposure to sunlight.

Earthing or Grounding

Studies have shown :

  • a reduction in pain and inflammation
  • better sleep,
  • reduce stress levels and the release of cortisol
  • improve blood circulation in the body

Drink at least 7 glasses of water during the day

As a programmer we are interested in achieving Flow state so that we can focus on solving complex problems. According to research, dehydration directly impacts attention, psycho motor and memory skills. Without enough water, you become more easily irritated, more sensitive to pain and less focused with frequent headaches.

Take frequent break during the day

Taking frequent break is essential for being productive and keeping a sane work life balance.

According to studies :

  • Breaks help decision fatigue.
  • Breaks help with staying focus on your task for longer time.
  • Breaks help reducing stress and exhaustion and replenish mental resources.

Take frequent holidays for example mini vacations

Taking mini vacations help you cut off from work, stay motivated and better appreciate life instead of the daily pounding, grinding and hustle.

You get the opportunity to spend quality time alone, with family and close friends.

By letting your body recuperate, you become more creative, productive and your problem solving is sharpened. While your stress is relieved, you feel healthier and avoid burnout.

Nowadays with the high pressure work and environment, mini vacations are highly recommended.


Seek to eliminate distractions before and during your work moments

The modern workplace is full of distractions, from open office plan to constant notifications from slack.

By reducing the amount of such interference, you can focus better on your work and achieve the Flow state.

Tips :

  • disable slack, hangouts and other app notifications before starting
  • put your mobile phone out of sight e.g under a copybook
  • wear an earphone or headphone to communicate you’re busy
  • use Pomodoro Timer



Abdallah Yashir

Senior Software Developer, Writer, Amateur Photographer, Reader