After publishing his own personal programming history, Ziggy asked if I might like to write my own. Since I don’t do a lot of writing, was referred to in the article, and mostly since he asked me to do so, I decided to go ahead and see what I could remember.
The first action similar to “computer programming” that I can remember is assisting my dad (a career computer programmer and information systems developer) in programming runs of EPROM integrated controllers for trackballs that he was developing as a side business. It wasn’t actually programming at all: my job was to plug in a chip, press the “up” arrow twice in a terminal emulator and run the command from history to erase it, press the “up” arrow twice more and run the command to write the firmware to the chip, unplug the chip, drop it in a chip tube, and repeat. I feel like I probably did hundreds of them (in fact, it was probably only dozens), and I loved every minute of the monotony, just because it got me closer to “working” on a computer.
Probably around the same time, my dad had a software menu in DOS on our 386. As I recall, this menu program automatically loaded when the computer started up, and had a password to keep me out of the “Games” menu. It also had, I learned, an escape sequence that would drop me out to the DOS prompt. This was well before the Internet, so my only reference for DOS commands was watching over Dad’s shoulder whenever I could. I eventually learned how to browse around to my games and run them myself.
Probably also around that time – I’d guess I was between 7 and 10 – Dad gave me a QBasic primer and installed a copy of MS-DOS QBasic. Because this was “educational”, I was allowed to work on programming even outside my 30 minute “game time” window, so I spent as much time on it as I could. I messed around with writing simple programs to play music notes based on key strokes, do simple arithmetic, and print out bits of text. Honestly, I didn’t get very far in any development of my own, but I did eventually discover that QBasic came with the code for Nibbles. I liked playing Nibbles, but I was too good at the first few levels and way too bad at the later ones. I opted for Kirk’s Kobayashi Maru solution: if you can’t win the game, change the rules. I experimented with changing the growth rate (usually with variations on multiplicative or exponential growth), the rate at which lives were removed after dying (why remove one life? why not remove -2..2 lives?), and a few other things. I eventually wanted to write my own game, and recall laboriously generating tone-by-tone theme music and an opening image in ASCII art, but never really figured out a reasonable first step in facilitating control. Worse, I had no real goal in mind other than “make a game” so it’s no surprise that the project died shortly thereafter.
After elementary school, I don’t recall doing a lot of programming. I was going to school a lot, and generally my electronic diversions were aimed at building, setting up, and maintaining my own computer. I did a lot of writing, had a couple of jobs, found a girlfriend, and then… I went to university. There, I enjoyed a quick revitalization of my old programming hobbies as I worked through the three low-level computer science courses that I could justify as electives in my Mechanical Engineering degree. Primarily, those classes helped me to discover an important fact: with programming, you can make computers do things that you don’t want to do yourself.
The university gave us all a copy of Visual Studio 6 for free. I wrote a probability calculator in C++ that used a brute-force algorithm to calculate confidence bands around target averages on multiple dice rolls… had I waited a year until I took statistics, I’d have known there were much easier ways to do that. I also got tired of filling up pages of paper with emplacement points, credit costs, and equipment inventories for building spaceships for a role-playing game, so I worked up a Visual Basic program to keep track of all those things which made building ships much simpler, even if I did miss things in the documentation like the “clear” method on combo boxes, making for a fairly miserable UX when working with larger vessels.
Then in 2004, I got married (win!), World of Warcraft came out, and my wife wanted to play it. We did so — a lot. So, when she got tired of manually sorting her Warlock’s Soul Stones into a particular bag I found the LUA online documentation and went to work. I eventually started maintaining three separate mods for the game, adding features missing from or general quality-of-life improvements over the base game. Then I got a job, we started having kids, we quit playing, and I quit coding.
Sometime around then, two developments came about. First, I started developing websites in PHP. Honestly, I don’t remember why or how I started doing this. It had something to do with phpbb, or WordPress, or something similar that wasn’t doing quite what I wanted to do. So, I learned to do some simple PHP. Then I learned HTML and CSS, and actually got paid to make a couple of websites. Much of this was thanks to another friend, who has been developing and maintaining his own commercially-successful website since early in his college career (if memory serves), who – apart from a lot of help learning PHP — also gave me the confidence that comes from knowing that someone else has already done what you’re trying to do.
Secondly, Ziggy had been using Python to do really cool stuff with procedurally-generated geometry in Blender, procedurally-generated trees in Minecraft, and other such awesome. He had been raving about Python for some years now, and honestly I’d always felt Python seemed like a real crock of a language. I mean, indentation-dependent logic? Nonsense! Nevermind that all of my code was compulsively indented — being required to do it was simply balderdash! I honestly don’t remember what I did in Python first — it was probably a parser for text files or something like that, or maybe I was helping him to do some simulation or another — but it proved a simple, easily-portable tool for automating all manner of work that would take me (sometimes literally) forever to do myself.
Around this time I also read The Pragmatic Programmer, (thanks to Ziggy’s recommendation) which really inspired me to stop wasting time doing and re-doing monotonous tasks that a computer can do for me. Just as an example, as a part of my day job I occasionally need to look for all of our projects that haven’t had any meaningful interaction in a certain period of time. I could do all that on my own, but the task is either very time consuming, requiring me to look at almost every file in any folder with an old date on it, or very inaccurate, depending on folder modified dates as a reasonable metric (which is not a valid assumption in NTFS). Or, I can spend 30 minutes whipping up a python script to do it for me! Now I never need to spend more than 30 seconds at it again. I’ve used python now for everything from parsing text files to harvest rule information from video games to simulating air flow in a compressed air system to performing hourly and daily backup functions for the office.
The most recent development has been entirely due to Kerbal Space Program (also introduced to me by Ziggy; that guy apparently has a good bead on “stuff Toad likes”). When an update to the game broke one of my favorite plugins, my options were clear: blunder about blindly like a Luddite or learn C# and fix it myself. Not much of a choice, I thought! I took over development of that that plugin, and have since started two of my own. Not counting comments, blank lines, or lines that are nothing but an open or close brace, my C# code base is now over 8,000 lines. C# is tons of fun to work with, and the portability of .NET programs means I don’t need to sacrifice my preferred Linux environment to use it.
Programming is about so much more than coding: it’s about learning and adopting a holistic, systematic approach to program solving. It’s looking at a situation and seeking to understand it both as a whole and as the parts that make the sum, then formulating a logical response. Made a habit, this has applications far from the text editors and integrated development environments of the coding desk. So, the next time you’re about to sit down and waste half an hour manually clicking every improperly formatted spreadsheet cell, or opening three different dialogs for every little change you want to make in a model, think through the problem and go find a way to teach your computer to do the hard work for you. Maybe an automatic hotkey would do? Alternatively, if that’s not relevant to you or you just don’t like the idea, go play SpaceChem. At $10 it’s one of the cheapest, most effective, most fun programming tutorials I’ve ever encountered. It won’t teach you a programming language or supplant an education in the field, but it will teach you to think like a programmer. And you won’t even realize it.
This article reminds me of the one comparing magic and technology, because it’s comparing games and programming.