Here be weird programming habits!

Whether due to boredom, OCD or unrequited love, software developers can develop some real idiosyncrasies

habit-600x450_0.jpgImage credit: flickr/bixentro
Sitting at a computer all day can lead to strange behavior

Weird habits - we all have them, though some of us have more of them - or weirder ones - than others. Some professions, in particular, seem to either foster stranger habits or tend to attract people with odder quirks than others. Baseball, for example, is littered with characters famous for their strange rituals. But what about software developers? Would it shock you to know that people sitting at computers writing code all day can also develop some idiosyncrasies? We thought not.

Recently on Quora - and less recently on Stack Exchange - developers have been sharing their odd programming habits. Turns out that programmers, not surprisingly, have quite the range of quirks. On the low end of the crazy scale, you have a lot people doing things to make code, in their opinions, at least, more readable.

I always have to have the braces on a separate line.

Nishant R Krishan

I can't stand saw toothed variable lists. I always space them to line up nice and tidy.

Andrew Heidgerken

Everytime I see lines exceeding a fixed numbers of characters (80 or 120, depending on the language), I cannot resist to refactor so that the line can fit in perfectly in my editor :)

Son Nguyen Kim

Then you have behavior which starts getting a little less rational.

I am quite OCD about needing to remove any white spaces at the ends of lines.

Piers Myers

At least two Ctrl+S's to make sure it's saved.


Despite having a monitor that has a 1680x1050 resolution (yay!) and a coding standard that states we must have line widths of less than 100 characters, I still code to 78 characters where I can.

Kaz Dragon

One common habit among developers is to express their feelings through code comments, which some take a little farther than others.

A friend of mine has a habit of putting Here be dragons! in a method's comments block if the code is a bit of a hack.


I add random smileys whenever I figure out a solution to a problem I'm struggling with in my code.

Abhinav Desor

I used to put rants with lots of 4 letter words in comments.

Makiko Itoh

Some folks have some fairly unusual (and, some would say, creepy) quirks when it comes to variable naming.

Assigning a string with my CRUSH name in it to a variable.


I assign names of porn-stars to any string(s) required in the program.

Aditya Aggarwal

I do a lot of competitive programming where I have to finally come up with an answer.... I name the variable which is to be the final answer as my present girlfriend's name just hoping that one day I will crack all the mysteries behind a girl and her mind like I am solving that programming problem.


Finally, there are some habits that are truly out in left field.

When I'm being lazy, Instead of typing lengthy debug messages and printing them, I use windows Beeps to make a melody.

Ruddra Dev Roychoudhury

Being a big fan of Nolan's Inception I sometimes I think that I'm dreaming so whenever I'm on my PC I press ctrl key to check if I'm dreaming. I have enabled mouse pointer shadow on my PC to show the circle around the mouse pointer whenever I press ctrl key. I consider it as my inception totem.

Sarvesh Ranjan

I have the main soundtrack from the movie "The Social Network" playing in the background cause my alter ego is a brilliant nerd of an asshole that dropped out from Harvard, just like how the movie depicts Mark Zuckerberg. It gets shit done. No lie.

Chezza "ZomgACrayon"

The takeaway from all this: programmers, not surprisingly, do indeed have some weird habits. Also, if you want to know whether a developer likes (and is possibly stalking) you, take a peek at his code.

Do you have a strange programming habit? Let’s hear it in the comments.

Read more of Phil Johnson's #Tech blog and follow the latest IT news at ITworld. Follow Phil on Twitter at @itwphiljohnson. For the latest IT news, analysis and how-tos, follow ITworld on Twitter and Facebook.

ITWorld DealPost: The best in tech deals and discounts.
Shop Tech Products at Amazon