Programming and Ice Cream

There are connections between programming and my favorite ice cream.

In our new book on Django, I used the sentence “My favorite ice cream is Herrell’s” in some example code where I needed text – a tribute to my favorite local ice cream parlor.

Walking by Herrell’s this afternoon, I saw Steve Herrell inside. Because I had a copy of my book with me, I decided I’d see if he wanted to take a quick look at the code snippet. He did. He took this odd testimonial with grace and good humor, and thanked me.

Then he surprised me by bringing up a connection between programming and his ice cream that I hadn’t considered. Mixins.

In ice cream, mixins are chunks of good stuff like chopped up Heath Bars. Herrell is the man credited with inventing this practice. He did this in his first parlor, Steve’s Ice Cream, in Boston (Somerville, actually) in the ’70s.

In object-oriented programming, a mixin is a class used to add specific attributes or features to another class. Not so much a “parent” class as a clever uncle. Some sort of mixin funcionality is possible in any language with multiple inheritance, as far as I know.

What I didn’t know until reading the Wikipedia article on mixins was that the programming term itself was inspired by Steve’s Ice Cream! This adaptation of terminology was the handiwork of workers at Symbolics, a Lisp company headquartered in nearby Cambridge.

So, not only did today’s little outing give me an excuse to get a dish of Key Lime Cardamom ice cream, it gave me a fun new bit of trivia as well.

akahn commented :

Mm, key lime cardamom. I didn’t know the book was out, congrats!

sharon fisher commented :

hmm. When in the 1970s? I went to the Cream Machine, in downtown Troy, in 1977, and that was the first place I encountered mixins.

Joe Brandt commented :

I think I’ll have to gather up the kids and make the trip over the river to go to Herrells again. It’s important for them to understand history (even if it only matters to their father), and if eating ice cream is part of that process then so be it.

Paul commented :

Sharon – according to the Herrell’s website he started Steve’s in 1973 and sold it in 1977. So, I guess the answer is, somewhere in between!