Skip to content

Instantly share code, notes, and snippets.

@jdavis
Created March 31, 2015 20:43
Show Gist options
  • Save jdavis/cd30675e2319aaca4df8 to your computer and use it in GitHub Desktop.
Save jdavis/cd30675e2319aaca4df8 to your computer and use it in GitHub Desktop.
Python Functional Puzzle
def cons(x, y):
return lambda f: f(x, y)
def car(x):
# Fill out this function
pass
if car(cons(1, 5)) == 1:
print 'Solved!'
else:
print 'Keep trying...'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment