February 27, 2006

Was your job picked for you by a high-school kid?

From the much-longer How to Do What You Love by Paul Graham:
Don't decide [on what you love to do] too soon. Kids who know early what they want to do seem impressive, as if they got the answer to some math question before the other kids. They have an answer, certainly, but odds are it's wrong.

A friend of mine who is a quite successful doctor complains constantly about her job. When people applying to medical school ask her for advice, she wants to shake them and yell "Don't do it!" (But she never does.) How did she get into this fix? In high school she already wanted to be a doctor. And she is so ambitious and determined that she overcame every obstacle along the way—including, unfortunately, not liking it.

Now she has a life chosen for her by a high-school kid.

Posted by ronlusk at 02:08 PM

February 16, 2006

Tinkering with Code

I used to write a lot of code—for a solo programmer in “the old days”, perhaps, a hundred-thousand-line program was a lot—in C, C++, and (more recently) Java. This passage from an essay by Trevor Blackwell just rang true.
The best qualities of high- and low-level languages

A well-written program in an abstract language like Ocaml or Lisp has the quality of an elegant mathematical proof: beautiful and concise, but you can't change anything without breaking it. Most programs in C++ are more like an elaborate model train layout, supporting endless tinkering without actually stopping the train from going 'round.

Of course, these days the tinkering can be more intentional, and we call it “refactoring” (“I'm sorry, I can't attend that meeting, this code has some bad smells, and really needs refactoring” might buy you more time than, “Sorry, I'd rather tinker with this old program; have a good meeting.”).

Since I started writing in Ruby (and also, less skillfully, in Python), I've had much less tinkering to do: getting some things done in Java, or in (old-style: I haven't worked a lot with the C++ STL, so things may be different) C++ just needed a lot more little helper classes here and there to sort or iterate or whatever, and they could all use a little polish and dusting from time to time.

On the other hand, there always seems to be more to do, so turning out fewer lines of code for any one task is a good thing, and lingering over it (when it does what it's supposed to and is relatively clear) just doesn't appeal as much as it used to.

Posted by ronlusk at 07:50 AM