Haskell

Good place to start learing Haskell

Lambda Expression

This is how recursive function looks like:
define fact = n.if (iszero n) 
                   1 
                   (* n ( fact (dec n)))

How do we implement this recursive function?

define f = λg . λn. if (iszero n) 
                   1 
                   (* n ( g (dec n)))
therefore, fact = f(fact)
fact function which is the function we want to define is called the fixed point of f function

Y Combinator

Y = λh.(λx. h(x x) )(λx. h(x x) )

We have:
Y f = f (Y f)

results matching ""

    No results matching ""