Tag Archives: retro

Retro Tech: The 200-year Old Computer

It was nearly 200 years ago (okay, 191) that Charles Babbage came up with the design for his Difference Engine, a mechanical calculator that could solve polynomial-based equations. In the 1820′s, he also sketched designs for a printer to go along with it!

What’s perhaps more amazing is that when, in 2000, the printer and difference engine were built, they worked perfectly. And they still do!

As we move ever faster into quantum computing, wearable computing, holographic interfaces, and all the rest, it’s sometimes useful to take a moment and look back. This week, to look WAY back, and celebrate one of the foundational moments of the technology.

The Computer History Museum in California has a working Difference Engine No. 2, and also has a wonderful interpretive website about it all.

Worth checking out!

Data Structures Are Dead…Long Live Data Structures!

Eons ago, when I was first learning how to code, we spent a fair amount of time focusing on data structures at the heart of development. In that time, both memory and fixed storage were expensive and scarce, so by learning how the base structures worked (and learning how to code them up from scratch), we could pick the most economical version and save an extra kilobyte of memory or two — a precious commodity!

These days, neither memory nor storage are terribly expensive nor scarce (although in our networked environment, there are still reasons to conserve). So it may not be much surprise that there are many programmers who couldn’t write an implementation of a doubly-linked list or b-tree.

Yet it’s not stopping them from being productive, great developers. Why? Because in today’s framework and higher-level language-driven world, those lower-level structures are often abstracted away or handled behind the scenes. Take Cocoa, for instance, which has classes for arrays, sets, dictionaries, and more — all with optimizations and methods to do querying, modification, and more built in.

Sounds like unbridled progress to many, and I certainly agree with the ‘progress’ part. But unbridled? I’m not so sure. I continue to think there’s value in knowing how the fundamental data structures work — for at least two reasons:

First, in knowing the internals, you can make more informed decisions about which to use when. With Cocoa, for instance, Apple has released a whole set of tech docs about the best uses for each of the “collection” types. It’s helpful and well-written, but mostly superfluous if you have the underpinnings needed to internalize that kind of thing.

Second, there’s still a role for optimization. Hardware and networks continue to get faster and frameworks continue to get more efficient — but it is poor form to rely on those increases when you don’t have to. And to optimize, there’s really no substitute for knowing the basics of how things work.

So maybe we’re seeing the slow erosion of understanding about low-level data structures like stacks, queues, and heaps. And for some, maybe that’s OK. But I’m not ready to see them go just yet.

Retro Geekiness: Sorting Out Sorting

As a child about thirty years ago, when I decided to transition from computer programming hobbyist to student, one of the big topics that represented that transition was algorithms. These “recipes for the computer,” as I was taught at the time, were the key — the secret to unlocking the potential of this great technology.

One of the first areas of algorithmic exploration I embarked on was sorting algorithms. Which, although it was probably a pretty haphazard selection, turned out to be a good choice. Even now, three decades later, knowing how sorting algorithms work and when to choose the right one comes up all the time.

But back then, it was a brave new world to me, and I was just trying to figure out how they worked at a basic level. It was a struggle — I knew that some were faster than others in certain cases, some really sucked all the time (using the vernacular of the time), but I was having a little trouble grasping the nuances.

Then one day, while I was idly flipping through my school district’s central film and video catalog (the depth of my geekiness as a child is unending), I saw — what’s this? — a video about programming! I quickly badgered the librarian to request it, and when it came, I beheld: Sorting Out Sorting.

This 30-minute video was created entirely on the computer in 1980 — an impressive feat by itself — by the University of Toronto. And it remains, I think, the best teaching material on sorting algorithms in existence. When I started teaching computer science, I went on to show it to several classes of students over the years, and while it’s certainly dated (oh, man, is it dated), the information remains stellar.

There really is no substitution for seeing the algorithms in action. These days, there are websites like this one that show you much of the same animations in a browser window, but the movie gives you more in-depth detail about each one.

This is by no means a film review website, but this is one I’d give two-thumbs up. Put some legwarmers on, turn down the Huey Lewis & The News for a minute, and check it out.