Sunday, November 8, 2009

How to not fuck up your kids (or why I didn't become a programmer until age 38)

Not only did I become a professional programmer at age 38 but I've got over 8 years of experience. So if you can do simple arithmetic you know I'm probably older than you are. Either that or you're really old. For a while I'd often run into programmers half my age with twice my experience. This phenomenon is becoming less frequent because of the following equation:

MyAge - MyExperience = MyAge/2 - 2MyExperience

At 40 with 2 years experience the young whippersnapper would be 20 and have started when they were 16, which certainly isn't unusual. But now, at 46 (rounding down for even number) and 8 years experience the whippersnapper would be 23 but would have had to start at 7 years old. Which is not unheard of. But when I'm 50 I'll have had 12 years of experience. This is discounting the possibility of doing a mid-life career change and becoming a Wal-Mart greeter. I don't think that's likely because I would not be very good at being a Wal-Mart greeter. I don't even think I could bring myself to utter the phrase "Welcome to Wal-Mart" with a straight face. The bastard is walking into Wal-Mart cause he wants something and he wants it cheap. Why does he have to welcomed? Especially by me. I don't give two shits if he goes to Wal-Mart or not.

Anyway, at 50 the whippersnapper would have to be 25 years old with 24 years of programming experience. Very unlikely. And at 60 said whippersnapper would have to be 30 with 44 years of experience. He (or she with a much lower probability) would have had to start programming at age -14. The square root of 38 is 6.164144. So I can exist. The square root of -14 is an imaginary number which does not exist. The probability of experiencing the aforementioned phenomenon is very low now and will soon be zero.

But that is all tangential to what I actually wanted to address. Which is why did I wait until 38 when I could have been one of the whippersnappers that eventually have imaginary numbers for the square root of their age of starting programming? There are a lot of reasons but one is critical, especially if you are a parent to homo-sapien children. Dogs you can treat differently.

When I was about 7 or 8 years old I used to like to sit in one of my parents cars and pretend I was driving (who didn't?). But I was also curious about how a car worked, particularly the engine and drive-train and how pressing the gas pedal would somehow make the car move in a direction. I didn't have any books on the subject, the web did not exist yet (though the Internet did) and video was limited to watching the 3 broadcast T.V. stations. See, I am really old. We did have cars though. I wasn't imagining that.

So because I didn't have any educational materials on the subjects of internal combustion engines, camshafts, or differentials I just had to sit around and think about it. I must have gotten some input somewhere (I think it was Saturday morning cartoons) because I eventually came up with this idea about how it all might work.

I decided that inside the engine were hollow tubes (cylinders) and they contained thick metal rods (pistons). The cylinders were longer than the pistons and so there would always be empty space between one end or the other or both. I surmised that if some gasoline were to be squirted into the empty space inside the cylinder and then lit on fire (I'd heard the term spark plugs so I figured they caused a spark) it would cause a small explosion. The force of this explosion would push the piston in the opposite direction and this force would be somehow translated into angular momentum (no I didn't know the term angular momentum, I called spinning). Once the piston had traveled to the other end of the cylinder it would bounce off the angular momentum translator thing and travel towards the other direction of the cylinder. Right before the piston got to the other side (where it had originally been) more gas was squirted into the empty space and ignited creating another explosion.

This hypothesis seemed reasonably likely to me so then I started to think about how the up and down (or back and forth) motion of the pistons could turn into angular momentum (spinning) to make the wheels turn. Before I pondered this in depth I decided I should tell my Dad my working theory to make sure I was on the right track. It probably wasn't that so much as wanting to show off to my Dad how smart I was for figuring all this out.

After explaining the above hypothesis and asking if it was right, my Dad told me "no, that's not at all how it works, it's much more complicated than that". Well, this was a crushing blow. After all I had strained my 8 year old brain pretty hard trying to piece this conjecture together and if it was not only "completely wrong" but also "much more complicated" then I figured I just did not have the intellectual horsepower to think about things like this.

A year or two later I discovered something I was good at. I could walk into a 7-11 store and steal candy bars consistently without being caught. I'd use the clerk's own mirror (the one he's supposed to be using for watching me) to watch him. I could tell without looking at him that he was busy and make the grab. Then I'd go ask him if he stocked something that I knew he didn't have and when he told me he didn't stock it I had a perfectly plausible explanation for leaving the store without buying anything.

Why my Dad answered the way that he did I still don't know. Granted I wasn't exactly right but it wasn't "completely wrong". It is more complicated, there are pressure differentials and exhaust mechanisms, etc. But nothing that couldn't have been explained to me. My best guess is that my Dad didn't really know how an internal combustion engine worked but knew an 8 year old didn't either so it was just easier to tell him it was too complicated.

For the next 17 years I thought of myself as not being a technically inclined person. I was good at crime because I was good at understanding how other people thought and finding the flaws in that. I shoplifted when I was younger, sold drugs when I was older and did a myriad of other things that seemed pretty simple to me but other kids seemed to always get caught at. The only time I ever got caught was when I followed someone else's advice instead of thinking for myself. But my criminal career is a subject for a different post.

When math class started to get confusing I probably decided that it was also "too complicated for me to understand". Algebra seemed hopelessly arcane. I didn't learn algebra until I was in my thirties. I taught it to myself and it wasn't really hard at all. In Junior High shop class, when my device didn't work it reinforced by belief that I wasn't cut out for anything engineering.

The change began when I worked in the mail room of a newspaper company. Since I had pretty much given up my life of crime and was a geek without technical skills my job options were limited. There were 4 others in this particular mail room. One thing that had to be done daily was reconciling the amount of mail we had sent out with the reading on the postage meter. The "senior" mail room employees would do this task because it was an extremely difficult task to accomplish. There was almost always a problem. More than once they complained to management that something was wrong with the 10 key calculator they were using, it must be adding the numbers incorrectly. I remember being called into the bosses office, I thought I might be in trouble, but she really wanted to get my opinion if I thought there was any validity to the idea that the calculator was computing the numbers incorrectly. I also found out that this was a new calculator because they had already replaced the old one for it was also giving incorrect answers. I didn't understand much about probability theory at the time but still it seemed unlikely that two calculators made by Texas Instruments and were only two of the hundreds used by our company were both malfunctioning and both happened to be assigned to the mail room. I told her that I guessed it was possible but I really doubted it. I agreed to become the new balancer of the tapes and meters to the chagrin of the other mail room professionals. After about 15 minutes of reconciliation I found the problem which proved that the calculator was indeed giving the correct answers and the humans were making not quite as correct inputs.

To make a long story slightly less long I became the expert at how to fix the various machines after watching the Senior Mail Room Professionals bumble around complaining about the machine's design. I also invented a sequence for the work flow of the mail room that reduced my 8 hour a day job to about an hour and a half (and I could read the newspaper while all the machines were running at once). Consequently I could run the whole room by myself if everyone else happened to be sick. Eventually I was only called in to balance the tape and meter when they could not balance the two sets of numbers which suited me fine, if there wasn't a problem to solve it didn't seem very interesting to bang numbers into a calculator.

Eventually the company decided that I might be useful in other areas so they moved me up. I don't know exactly how I'd describe my position but to say it always involved figuring things out that were out of the ordinary. So I realized I was adept at working with numbers, not mathematics, but problem solving in the bookkeeping and analysis realms. This led to a job as purchasing manager where I shunned the offers to attend basketball games and other supposed inducements from vendors and instead concentrated on building spread sheets to analyze where money was being spent and how we could achieve the same results spending less. It wasn't because I was noble, it was because I'd rather play around with numbers on a spread sheet than sit and watch people I don't even know play basketball for 2 hours. This confused the salesmen to no end. My crowning achievement here was the development of a spreadsheet that would tell me (based on the price of oil and the time of year) exactly what I should pay for the polyethylene bags we bought to put newspapers in when inclement weather was expected. This eliminated a huge effort every year to "put the polybags out to bid" and also established extreme vendor loyalty. As long as you're charging me what you should be charging me then I'll only buy from you. In turn you make sure when there are capacity shortages our orders ship first. This saved our ass during the El Nino weather pattern in the late nineties.

At some point I began to feel the limitations of spreadsheets and, encouraged by my boss, began to learn to write software. I ended up writing a lot of software. It wasn't very good, but it worked and saved huge amounts of time and made analysis possible that wasn't before. I spent most of the last year in my 3 year career as a purchasing agent writing code instead of being wined and dined by salesmen. Again to their utter bafflement.

Eventually I moved into a job where I was programming full time, this was circa 2001 although I had written a lot of code on the side prior to that including a Y2K fix. I could do this. It wasn't mathematics (not much anyway) and it wasn't hard mechanical stuff. It was software, it was soft. This was a technical thing I could do.

One day I was trying to fix the shower. I can't remember exactly what was wrong with it but I do remember that I let an essential washer fall down the pipe where it lodged itself just out of reach of a wire close hanger fashioned into a hook. My mind started churning, kind of like it did when I was 8 and trying to figure out how a car worked. How could I get that washer? I could go buy another but I am lazy and plus how would I know what size without the original? It hit me in a few seconds. Turn the main water line back on and the resulting water pressure will blast the washer back out of the pipe. It worked like a charm, although I did get wet. Another time we were camping and my son had a remote controlled truck. It suddenly stopped working. We put new batteries in it, still didn't work. In an earlier time I would have declared it broken but years of writing code had developed my problem solving abilities in ways I had never anticipated. Later that evening the truck suddenly started working again. I had my answer! The next day as it heated up, the truck stopped working again, as I had expected. I looked at the battery compartment and saw that it had expanded slightly due to the heat and the terminals of the battery could not quite reach the contact points. I broke the head off a match stick and stuffed the stick into a space between the compartment and the contacts, forcing the contacts to come in ...uuhhhh...contact with the battery terminals. Worked just as well as if MacGyver had done it himself.

So, by programming I had tricked myself into thinking in a way conducive to general problem solving. I decided to teach myself math. It was much much easier than it was in school. I taught myself some formal logic, this was still hard but I could do it. I'll never be a genius but I'm pretty sure I can learn some pretty hard subjects.

Anyway, be careful how you speak to your children. You might like it better if they decide to become mechanical engineers instead of drug dealers.

No comments:

Post a Comment