-
-
Save havenwood/9af042826d7288f52df8da396235951b to your computer and use it in GitHub Desktop.
The symmetry pointed out in: http://confreaks.tv/videos/rubyconf2012-y-not-adventures-in-functional-programming
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def z_combinator f | |
->(gen) { f.(->(_) { gen.(gen).(_) }) }.( | |
->(gen) { f.(->(_) { gen.(gen).(_) }) } ) | |
end | |
def z_combinator f | |
->(gen) { gen.(gen) }.( | |
->(gen) { f.(->(_) { gen.(gen).(_) }) } ) | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment