Speaking of planes whose engines quit

I was just reading the story of British Airways Flight 9 on Wikipedia. I hope that some day when I get into difficulty as a pilot, I’m as calm as Captain Moody:

Ladies and Gentlemen, this is your Captain speaking. We have a small problem. All four engines have stopped. We are doing our damnedest to get them going again. I trust you are not in too much distress.

That’s just beat out Captain Al Haynes “You want to be particular and make it a runway, huh?” as my favourite aviation quote.

That’s me in spades

I just finished reading How To Recognize A Good Programmer, and kept thinking “hey, that’s me” for every point. So why did my last two job interviews not go so well? I’m a good programmer, I know I’m damn good actually, and according to this, everybody else should think I am too.

Oh well, I’ve got 6 months left on this contract. Maybe I should get some paper qualifications to impress the people who aren’t smart enough to read that article.

I feel so dirty

For this current project I’m on, I’ve resolved to give Eclipse a try. This is a major step for me, because my fingers have been typing vi commands for 20 years now, and it’s really hard to get out of the habit of typing “[escape]jjjjj” or “ZZ”. Everybody else here laughs at me because besides etags and the syntax colouring of gvim, I don’t have all the fancy stuff that they have. On the other hand, I can do everything through a ssh connection and can keep my hands on the home row.

Oh well. Welcome to the 21st century. Here’s your kazoo.

How the hell did I miss that?

I’ve been doing Java since 1998, and yet I only just discovered this interesting fact. If you have a class called, say, DBAsset that has a bunch of static methods in it, and you have some static member variables, and you initialize the static member variables, like so:

class DBAsset
{
static PreparedStatement insertStmt = null;
static PreparedStatement deleteStmt = null;

Then calling multiple static methods from within DBAsset’s static main using just the unadorned method name doesn’t do anything to those variables, but each time you call one of those static methods from some other class using DBAsset.methodname, those static variables get reinitialized to null. Huh.

Update: Figured it out. The code that initialized the variables was getting called *before* the code that set it to null, because I had a static DBAsset theAsset = new DBAsset(); before the static initializers. I’m such a slaphead.