The Underscore is over-rated

After years and years of abuse, my pinkies can’t take it anymore and have hijacked my remaining fingers (and the thumbs) into writing this post.

So if you are a developer, a database designer, or just writes APIs or SDKs or programming languages or opensource code that other people will reuse, and if you love coding conventions, and if you like using the underscore ‘_’ as a separator, please STOP RIGHT NOW!. Think of all the little fingers that you will save!

If you are still not convinced, try typing Q_Q_Q_Q a few times. See?

camelCase is just as good for variables, and FirstLeretterCapitalization should be sufficient for functions names. It is bad enough that the curly braces {}, the Backspace and the Enter keys are so far away from the left little finger, and yet it has to cover all those keys – please don’t make it any worse by these horrible underscores!

The generation before us (the pioneers of computer science etc. etc.) probably started using computer keyboards in their middle ages, my generation (in Pakistan at least) started using computers in our teens, and if my son is a good representative sample, then TNG (The Next Generation) started using computers before they learned how to write. This means their poor little fingers will get an extra decade or so of keyboard exposure. The pioneer generation didn’t have a clue, but we do – most of us 30 somethings have aching fingers (or is it just me?) each day, after spending half the day in front of the computer. Let’s make the world a little more pleasant for our kids.

So the next time you get this urge to use the _ in your code, please reconsider. Thank you!

7 Comments

  1. Suleman says:

    hehe, I liked Q_Q_Q_Q analogy

  2. Aqeel says:

    Sohaib, you need this:

    http://www.thinkgeek.com/homeoffice/gear/a33b/?cpg=cj

    Went through your blog. a bunch of nice posts here. I am adding your link on my blog.

  3. Sohaib Athar says:

    @Suleman if you are programming in Qt, Q is a character you need to type really often 🙁
    @Aqeel Thanks for the link and the recommendation – I would prefer to change OBJECTS to suit me rather than change myself to suit badly designed objects.
    I already use DVORAK off and on, it is not a great layout for C++ style syntax (and includes Java/PHP/C# etc.) I can see RSI dominating my wrists very soon, and have a couple of designs in mind that I need to try out. More about those in a later post.

  4. Suleman says:

    Come on, post something new already. Don’t keep us waiting for so long. 🙂

  5. cachedump says:

    Everything alright? Haven’t heard from your blog lately

  6. Babar Bhatti says:

    I’ve often thought about this … especially when I the pain in my hands/wrist forces me to wear the ‘wrist guard’.

    TNG will make fun of us … really? you guys used to TYPE everything?

  7. Sohaib Athar says:

    I finally found the keyboard I need for a little experiment in ergonomics – now I need a few hours and a screwdriver 😀