letexpressions in Lisp. I used to write out the equivalent
lambdaexpression and then manually add the syntactic sugar to make it into a
let. And I don't recall having an easy time with the chapter on linked lists. So I find it amusing to see what tortuous code students come up with when they are first introduced to linked lists. My favorite so far has been
append elements), which looks like it might join the sublists in
elements, but if you think about it, the arity is all wrong: map doesn't apply its function, it calls it. This had me scratching my head for several minutes until I realized you can call apply on a single argument.
So what little gems of code have you discovered that perform the most trivial of tasks in the most convoluted or obscure manner?