Why functional Python matters

Ivan Boldyrev boldyrev+nospam at cgitftp.uiggm.nsc.ru
Sat Apr 19 01:12:03 EDT 2003


On 8353 day of my life Thaddeus L. Olczyk wrote:
> 
> >> >And you have to be a bit relaxed when using this requirement; for
> >> >instance, writing an Y-combinator in ML is very hard because of the
> >> >stupid type checker.

> >> No it is easy.

> >> In OCaml, 
> >>     let rec fix f x=f (fix f) x;;

> >That's cheating and you know it :-)

> No. It's not.
> It's a standard definition of Y in a combinatorial approach
> to computing.

But 'let rec' does Y-combination behind scene.  So, it is trick.

Try to implement Y-combinator without rec...

-- 
Ivan Boldyrev
PGP fp: 3640 E637 EE3D AA51 A59F  3306 A5BD D198 5609 8673   ID 56098673

        Outlook has performed an illegal operation and will be shut down.
        If the problem persists, contact the program vendor.




More information about the Python-list mailing list