How Do We Read Code?

I was directed to a blog post today that I felt was interesting so I’m sharing it with you.  The author participated in an experiment to to see how people comprehend programs.  The goal is “to figure out some way of measuring what features in programming systems help programmers understand what they are doing.”

Interesting post and pretty cool video showing the eye movements while he was figuring out a Python program.  I highly recommend viewing it.

What caught my eye though, was this statement:

…there seems to be some evidence that following variable naming conventions helps experienced programmers understand the code much quicker, while breaking these conventions leads to a severe penalty.

From my own experience this is true.  When I’m working with code that someone from my own development team wrote it’s very easy to follow and understand and modify.  OPC (Other People’s Code) projects take longer to figure out because invariably they don’t use the same standards (if they even have standards).

So I guess the moral of the story is that as you become more proficient in whatever language you use you should start using naming standards.  It’ll help you in the long run become a more efficient programmer.

Happy Coding and Happy Holidays!

1 thought on “How Do We Read Code?

  1. Hi Bob,

    I think I mentioned it before but maybe you could post the list of abbreviations you use. The more people adopt it the closer we get to a universal coding style 😉

Comments are closed.