News for hackers. Stuff that matters.
Re:ASK HN: How are you becoming a better programmer? by hga on Tuesday February 16, 2010 @07:14PM (#1130393)
For me it was the stroke of luck in my first programming experience being punched card FORTRAN IV (but more like a II, no logical IFs) on the IBM 1130 in the fall of 1977.

I realized there had to be a better way and so I went straight to the library and read up on the software engineering of the time ("structured programming").

Since then I've read a lot on the practice of programming and applied it to my programming. And kept reading and applying stuff; the key here is to never stop learning.

Studying good software was probably the other major way. Back then, it was learning the UNIX V6 kernel with Lions' Commentary on UNIX 6th Edition, with Source Code plus reading the sources of all sorts of things and working on some of them.

If you haven't read The Pragmatic Programmer, AntiPatterns: Refactoring Software, Architectures, and Projects in Crisis, something by Gerald Weinberg and something by Tom DeMarco and Timothy Lister (Peopleware is pretty much required reading), and The Mythical Man Month I strongly recommend them.

The recent Coders At Work is really good, although at a somewhat higher level.

My other recommendation is to get serious knowledge of other domains that have useful ideas and metaphors; for me that would be science in general and biology in particular.

Hmmm, reading a lot of classic SF (from the '40s on) and studying nanotech also helped. You want to have a big bag of problem solving tricks.

It also helps to gain a top to bottom understanding of how it all works. There are many approaches and books for this, I like The Structure and Interpretation of Computer Programming (SICP) for the higher level stuff, but also be sure to study some EE, digital design and low level architecture. And operating systems.

And if you're at all good with your hands, build (assemble) yourself a computer and get UNIX/Linux running on it. Design and implement a network with routers and static IP addresses or something like that. Etc.

Re:ASK HN: How are you becoming a better programmer? by hga on Wednesday February 17, 2010 @12:34PM (#1131932)
Can't believe I forgot this one:

Don't just read code, reanimate it!

Find a large and dead (abandoned) body of code, one where you're not in a position to get much if any help from someone who had a hand in writing or maintaining it, and bring it back to life (e.g. get it running on current systems or a different system).

That makes the difference between simply reading code and really learning the code. Do enough "software archeology" and you'll be able to do all sorts of things: figure out within a few minutes the likely quality of a large body of code, recognize the different people who wrote or changed different parts of it (as in person A, person B...), learn that comments are at best what someone hoped at one point in time what some code would do, etc.