Tuesday, May 29, 2012

If programming religions were languages

I generally agree with this post, “If programming languages were religions”, and not just because he said nice things about Python.

However, I'd like to comment on this point:

APL: ...you've always suspected that it's a huge and elaborate prank that got out of control.

That's a pretty accurate description of Scientology, but APL's story is different.

It started with Ken Iverson's 1962 work A programming language. This book was not intended as a programming language, but as an exercise in mathematical notation. Specifically, Iverson wanted to describe certain operations in abstract terms. For example, adding two 50-element vectors was generally described in programming terms as looping over the 50 addends and producing 50 sums. Iverson proposed that the “+” operator be defined on two conformant vectors as a single operation.

An IBM researcher, Herbert Hellerman, implemented a language processor for a subset of the notation, and from there it grew by word-of-mouth. At one point IBM tried to shut it down but the user community screamed too loudly, and IBM eventually sold quite a number of big mainframes just to run APL.

The notion that you can add two arrays with a single operator is taken for granted these days, especially in contexts like MATLAB and Mathematica and the excellent NumPy package for Python. Bits of APL survive in all these languages. For example, the “reshape” operator, which can turn a 1000-element vector into a 10×10×10 array, was the ρ (rho) operator in APL.

Monday, May 28, 2012

Parking enforcement, Lithuanian style

"There are very few problems in computer science that are not susceptible to brute force." (Ed Runnion, former NM Tech computer science professor)

Or in parking enforcement: (short YouTube video)

Sunday, May 20, 2012

One of these words is not like the others

This New York Times press release about a burger chain got through the spell checker. Can you spot the funny?

An innovative addition to Red Robin’s lineup of delicious milkshakes, malts and other dessert offerings, the Salted Caramel Shake combines soft serve ice cream, milk, and decedent caramel sauce mixed with Red Hawaiian Sea Salt and topped with whipped cream and red sea salt sprinkles.