Recursive lambda expressions (blogs.msdn.com)
submitted by
CharlieCalvert(7835) 2 years, 8 months ago
People sometimes complain that you cannot write a lambda expression that is recursive. Good old factorial, for instance, how to write that as a lambda expression? Well the fathers of lambda calculus, who invented the lambda expressions in the 1930’s struggled with that, too, and as you might have guessed they came up with a solution. In this post let us stand on the shoulders of those giants and see how you can get recursion into your own lambda expressions in C#. It may not be practical but it is fun!
|
category: C#
|
Views: 91
tags:
another
Everyones tags:
No tags
Your Tags: