Open henix opened 10 years ago
http://stackoverflow.com/questions/5337464/anonymous-recursive-function-in-scala
def y[A,B](f: (A=>B)=>(A=>B)): A=>B = f(y(f))(_)
Y-combinator 本来不能在有类型的函数式语言中实现。这里由于使用了名称绑定
http://stackoverflow.com/questions/5337464/anonymous-recursive-function-in-scala
Y-combinator 本来不能在有类型的函数式语言中实现。这里由于使用了名称绑定