the long shadow of cleverness in computer science

:: programming

By: John Clements

I don’t have time to write an actual essay here, so I’m just going to take a 5-minute break from what I should actually be doing to share with all of you (my millions of adoring readers) a thought that I’m having while teaching engineering non-majors how to program.

To wit: For the last fifty years, cleverness has been extremely important in programming a computer.

But that’s not really true any more, at least not for the vast majority of programmers.

But we still teach computer science like it is.

And I’ll stop starting my sentences with conjunctions now.

In the 1950s, 1960s, and 1970s, computers were generally speaking slow and small; fitting your desired computation into the time and space afforded by computation was a challenge. Programmers had to come up with clever encodings and clever algorithms. They did!

Now, in the 202s, computers are very large and very fast, compared to the programs that most of us want to run. There are exceptions, of course; weather simulations and “high-energy physics” still want as much computing power as they can get. Most of our computing tasks, though, are relatively more modest.

Unfortunately, we haven’t yet figured out how to teach programming in ways that focus on correctness and reliability.

Honestly, I think that’s because most of our teachers are still much more interested in working on problems that exercise their cleverness. There’s a strong parallel here to Math; for many math faculty, teaching a Calc 1 class doesn’t sound fun; there may not be much that’s challenging or interesting about the material, and much of the work is oriented around nurturing and caring for young minds, rather than inventing new and magical ways of thinking.

In computer science (which in many ways is just applied math), we haven’t yet reached this state, for the simple reason that we still have not developed the tools that allow people to efficiently generate correct and reliable programs. In other words, it’s not too late for cleverness! That cleverness, though, must be directed not at the students, teaching them how to write clever programs in complex and interesting languages; instead, it must be directed at the tools and materials that surround those students; we need to develop programming tools and teaching methods that efficiently endow those young minds with the ability to generate correct and