Thursday, April 10, 2008

Becoming a Geek

Way back before I quit engineering school at Stevens Tech (in 1965, just before I would have flunked), we had to write a program in Fortran II for an IBM 1620 computer. This was a decimal machine whose operating system was a deck of cards. Our programs were small decks of a few cards tacked onto the end of the operating system and the compiler.

Computer time in those days was expensive; it was added to the cost of tuition. I don't remember the actual prices, but when a program went out of control, it mounted rapidly.

At the time I wasn't aware that dividing by zero was undefined/impossible/not a good idea. The computer didn't know it either, because if your program did it, the computer would compute endlessly. There were also the infamous "DO loops," loops that never exited. My program did both at successive times. The operator suggested I run a trace to help debug the thing. But what I got back as a trace was a full tray of cards that, when printed, produced page after page of hexadecimal gibberish. I wrote a letter to my girlfriend on the backs of some of those cards; the trace listing papered the walls of my dorm room.

It was almost 15 years before I came back to computers. I was working at the Federal Research Division of the Library of Congress. FRD was only nominally part of the Library, doing most of its work for the Defense Intelligence Agency using primarily open-source materials. The Library was a great place to work because we had access to the stacks and all of the resources of Capitol Hill and the Washington area. FRD, on the other hand, was a stifling environment run by narrow-minded bureaucrats who hired young college graduates in area studies (like me) doing largely useless work on the public dole. We were Robert Redford in Three Days of the Condor, but without the glamour (or the danger).

Being a government agency, however, we had to spend any leftover money at the end of a fiscal year or we risked not getting it next year. We had a small (two-person) engineering group which purchased an IBM 5100 table-top computer with some of these excess funds one year.

The engineers never used it; one of them soon quit and the other preferred a slide rule.

I was bored, however, and I had always liked gadgets, so I started playing with it. The machine weighed about 50 pounds and had a top cover with a handle, as if it was supposed to be portable; for those days, I suppose it was. Fully-equipped, it had 64K of RAM (we called it "core" back then), a high-quality tape drive, and two languages in ROM, BASIC and APL. Disk drives didn't come along until the 5110 model. It had a 5-inch black and white screen. We also had the accompanying dot-matrix printer.

I started out with BASIC and finally discovered arrays, and how to program a loop properly. This machine knew enough to teach me that dividing by zero was forbidden. But I soon became bored with BASIC and punched the button that switched to APL.

The Game of Life in one line of APL

This was a challenge, and great fun! After all, why iterate through an array when you can operate on it in one swell foop? IBM was heavily into APL at the time, and I worked with it a lot, off and on, for the next 10 years or so. At FRD I programmed an indexing system in APL on that computer. Sorting and storing, say, 2500 names in alphabetical order on a machine with only 64K of memory and a tape drive was an interesting exercise. I learned later that they replaced the 5100 with a DEC mini-computer.

By that time, however, I had become a programmer.