5 sure-fire ways to become better at programming

My previous semi-humorous blog post on becoming a bad programmer generated a lot of reaction, so I decided to write one more, this time eschewing the humor (some appeared to not *get* it) and just jumping to the list directly.

1) Be an apprentice first

Becoming a programmer is like becoming a mason. In the medieval ages, a mason had to first become an apprentice, work hard for several years before becoming an independent mason and joining the guild. Unfortunately, no such process exists for programmers. It is my opinion that programmers need the same mentoring before they develop good programming habits. If you have never met or worked with someone who is a better programmer than you, you are unfortunate. Without the ability to work and see at first hand the habits and processes of great programmers, it is hard to become one. My ability to handle complex problems increased dramatically when I worked with great programmers.

2) Continually adjust your complexity mental models

Programming is purely a mental activity and has no relationship to any physical activity including typing. To become a better programmer, you will need to exercise and build up the part of the brain that deals with managing complexity and dealing with the relationships between countless objects.

So how do you actually get better at this activity? It is by continuously learning from mistakes and tweaking your understanding and process by which you manage complexity. When you continuously refine your complexity models, you get better at managing complexity more efficiently. There is no end to this process – as you work on more complex projects, you will add more tools in your arsenal to manage complexity inside your head. The important thing to realize is that a mental model exists and that you must act consciously to improve it.

3) Be curious about new trends in computing

Programming, unlike bridge building changes the basic tools and processes every 5 years. It is hard work to keep abreast of the changes. But keep up, you must if you don’t want to be left behind. From programming with punch cards, Waterfalls, Assembly, Windows, MFC, Java, J2EE, .NET, PHP, Ruby-on-Rails, REST, Agile Programming, Design Patterns, AJAX, you will have to keep up with the rapidly changing landscape. And I say this not to keep jumping on the latest fad, but to keep up so that you understand the latest technologies and the benefits (and cons). Programming is partly about building things efficiently and choosing the right tool for the job. To get that piece right, you *have* to know what exists out there. Otherwise your program will be obsolete by the time you are ready to release.

4) Understand the major pieces of the software stack

Joel Spolsky talks about leaky abstractions. That is when you work with any abstraction, it always leaks a little bit, allowing the ugly underlying complexity to seep through. When that happens, if you don’t have an understanding of the layer below you will be screwed. Say you are a web programmer, you need to know a little about HTTP. If you are a .NET or MFC programmer, you need to know something about how Windows messages works.

Modern programming environments are little like fishbowls. You can live happily within this world for eternity, but if you want to do more than what is provided within the confines of the fish bowl, you better learn more about the *outside*.

Learn a little about all the pieces of the software stack, from registers in a CPU to low level memory management, process management, networking and so on. You will never be surprised or stopped dead by the glass walls of your fishbowl.

5) Be passionate

To become better at programming, the one sure-fire way is to be passionate about it. You need to be genuinely interested in working, thinking and living in code. No amount of knowledge, experience will otherwise help.

Agree, Disagree? Let me know.

17 Responses

  1. Peter Hickman says:

    Master a new tool just because it is something new. Know subversion, learn git even if you never use it. Can you configure Apache with your eyes closed, learn lighttpd. Learn a new programming language even if you have no need for it.

  2. Madhan says:

    Good points. In addition to configuring apache eyes closed, how about adding Typing with your eyes closed?

  3. Marco says:

    “Understand the major pieces of the software stack”

    Should be the first !

  4. salman says:

    Your r the best programmer every thing you can do just thinking.

  5. Tin says:

    #6. You have to be lazy.

    If you are truly lazy, you will find the best way to make sure it works the first time (to avoid any debugging efforts), the code has maximum reusability, the code is most readable (to avoid spending time to explain it to your colleagues how it works), and all sort of other goodness.

  6. Lorenzo says:


  7. Seanfalloy says:

    That is what my dad and grandfather have always called the “Smart Lazy Man” A person Should do the least amount of work while still getting the job done right.

    –and for f*&# sakes use comments so you can read it later and so others can read it !!!!!

  8. Good advice! I think passion is most important, given at least a rudimentary amount of working knowledge

  9. Jeff Thalhammer says:

    I would also add:

    Read other people’s code.

    As software developers, we tend to put all our energies into writing code, but very little energy into reading it. In any other discipline, this would be ridiculous.

    And I’m not talking about your co-workers’ code, because it probably suffers from the same issues as your own. I’m talking about code that came from a completely different perspective. Open source projects are a great resource for this.

    Study the interface design, the coding style, the conventions. Compare them to your own preferences and debate the merits. At the very least, this forces you identify your own style and develops your sense of “taste.”

  10. Lx2 Coder says:

    Any idea what type of prerequisite programming language might be involved in order to do Apple iPhone App’s (not graphics intensive video games, just nice looking, helpful apps)? I’m not a programmer, but a Web designer (Flash, CSS, HTML, Javascript, PHP, etc.). I do know that Apple produced a SDK, but am curious if anyone else has gone through it… Thanks!

  11. Louis Dizon says:

    I totally agree! Although I need to work on my burning passion. LOL.

  12. […] blog CodeLathe offers some advice. This is true, and in line with the subtitle of this blog: Programming is purely a mental activity […]

  13. […] 4. 5 sure-fire ways to become better at programming […]

  14. Akbar says:

    Absolutely good points.

    One *has* to be passionate about programing, if it doesn’t come naturally, probably you ought not be a programmer.

  15. From S. Korea says:

    Here in Korea, many try to become a programmer. but most of them never graduate from colleges or universities. instead, they take the course on Java or C++ for 4 or 5 months

    AND!! I am one of them,. is it same in America… If not, can anybody tell me which i have to study first about JAVA…..
    I have read a java book and jsp… and what’s Next???

  16. JJ says:

    I’ve always believed that if you have drive and passion you can do anything. However here in the US, if one person has a bachelor’s degree in CS and you don’t they are more likely to hire that person who has the degree. Obtaining a bachelor’s degree is essential. Unfortunately in the US the cost of going to a university is out of this world.

  17. sudhakaran packianathan says:

    great advice.

Leave a Reply