## Oh no! Alligators!

One of my great joys on visiting Berkeley was to meet Bret Victor, of Magic Ink fame. I mentioned to him that I had been working with a student on a visual lambda calculus, in part because I wanted a way to explain lambda calculus to my eight-year old daughter and son. He responded with a game involving alligators and their eggs, such a clever morphing of lambda calculus that it wasn't until I reached the end that I realized exactly what was going on.

So far, I've had a chance to show it to my daughter, who managed to successfully solve the problem at the end. She guessed a definition of 'not', and then applied 'not' to 'true' and checked that the result is 'false'. But she was most interested in drawing pictures of alligators! I expect it would be more fun to use if there was software that implemented the game.

Bret also pointed to David Keenan's graphical lambda calculus, based on Raymond Smullyan's "To Mock a Mockingbird".

I loved the alligator game!

From http://bntr.livejournal.com/13102.html

Lambda-cartoons (animated gifs):

fst(e1,e2) = e1
http://ljplus.ru/img/b/n/bntr/lambda_fst.gif

mul 2 3 = 6 (Brilliant!)
http://ljplus.ru/img/b/n/bntr/lambda_mul.gif

Hi, my name is Micah Sittig and I'm a middle school math teacher. I'm thinking of giving the alligators to our math club as a fun activity, but I'm running into trouble even just doing the puzzle given at the end of the "Alligator Eggs!" instructions.

In trying to have NOT eat TRUE, I'm finding that an egg-less alligator will try to eat another family. When he eats the family, where do they go? (The problem stems from TRUE, FALSE, and the two lower families in NOT having two colored alligators protecting only one egg.)

Any clues? I know nothing about lambda calculus except that my EE friends at Caltech used it a lot learning Lisp in CS 20. Thanks.

Micah,

When an alligator without an egg of its color eats another family, the other family and the alligator that ate them are all dead. Its like constant function. Same result no matter what it eats.

Here is one more visual notation for lambda calculus: