re: The easiest problem you cannot solve. VIEW POST

TOP OF THREAD FULL DISCUSSION
re: eval(K.toString().replace('b', 'a'))(cat)(dog) This one is pretty creative. Modifying the original K function to swap a and b. I like it.
 

In hindsight I should have realized that turning the function into a => a => a looks suspiciously like the I combinator.

Exactly! That is definitely the I combinator. It works beautifuly with the K combinator in the problem to solve this problem.

Two parts of SKI combinator calculus!

code of conduct - report abuse