Skip to content

Instantly share code, notes, and snippets.

@dionyziz
Created November 29, 2011 19:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dionyziz/1405991 to your computer and use it in GitHub Desktop.
Save dionyziz/1405991 to your computer and use it in GitHub Desktop.
What does this piece of code do?
( ( function( f ) {
return ( function( x ) {
return f( function( n ) {
return ( x( x ) )( n );
} );
} )( function( x ) {
return f( function( n ) {
return ( x( x ) )( n );
} );
} );
} )(
function( g ) {
return function( n ) {
if ( n == 1 ) {
return 1;
}
return n * g( n - 1 );
};
}
) )( 5 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment