/ HackerRank Functional Challenges

HR F#: Lambda Calculus - Evaluating Expressions #4

This problem just checks how well you have got the idea of Church encoding while solving the previous problem.

Compute the value of λx.λy.x(xy).

Just by looking at the definition of the Church numerals it is easy to see that this function corresponds to number 2. And this is the right answer.

Alex Netkachov

Alex Netkachov

Alex works at Central London on the next generation of energy trading solutions to traders, brokers and exchanges worldwide.

Read More

Why not to stay updated if the subject is interesting? Join Telegram channel Alex@Net or follow alex_at_net on Twitter. Or just, use the comments form below.