Lambda the Ultimate

inactiveTopic Programming Challenge
started 2/2/2002; 1:15:54 AM - last post 2/5/2002; 8:53:40 AM
Ehud Lamm - Programming Challenge  blueArrow
2/2/2002; 1:15:54 AM (reads: 2268, responses: 5)
Programming Challenge
(via Keith Devens)

For the last problem you must know a bit of Lisp. The rest can be done in any language you want.

Anyone wants to post cool solutions, in cool languages?
Posted to fun by Ehud Lamm on 2/2/02; 1:16:59 AM

Dan Egnor - Re: Programming Challenge  blueArrow
2/2/2002; 6:49:08 AM (reads: 1431, responses: 0)
Nine 9's

I know, C++ isn't very cool, sorry. The Mystery M Function is best solved not by writing code.

The authors told me they thought all three puzzles were of approximately equal difficulty, though perhaps tuned for different proclivities. (Note that you only need to solve one to apply for a job.) But I, and everyone I know, find Add-A-Gram much easier than the other two; I found the Mystery M Function took quite a bit of work to decipher.

Iuri Wickert - Re: Programming Challenge  blueArrow
2/2/2002; 8:52:39 AM (reads: 1374, responses: 0)
The company has banners in slashdot for a couple of months now. I wonder if they aren't getting enough applications ... For my job application I solved the add-a-gram (the easiest one, imho) in python. The catch is to choose the right representation to the words and graph structure, and to do the search backwards... Anyway, I didn't get the point in the Mystery Function (proof of convergence?).

Noel Welsh - Re: Programming Challenge  blueArrow
2/4/2002; 12:37:59 AM (reads: 1325, responses: 0)
The mystery M Function uses an extreme amount of stack, but presumably does eventually converge. It's similar to Ackermann's function but I suppose you can prove the convergence which AFAIK hasn't been done for Ackermann's function.

Christian Langreiter - Re: Programming Challenge  blueArrow
2/4/2002; 3:14:25 PM (reads: 1302, responses: 0)
An add-a-gram solution in K:

Enjoy ;-) -- Chris

Iuri Wickert - Re: Programming Challenge  blueArrow
2/5/2002; 8:53:40 AM (reads: 1275, responses: 0)
A python solution, semi-recursive style: