阅读背景:

如何知道f#中的函数是否是尾部递归的

来源:互联网 

I wrote the follwing function:

我写了下面的函数:

let str2lst str =
    let rec f s acc =
      match s with
        | "" -> acc
        | _  -> f (s.Substring 1) (s.[0]::acc)
    f str []
le



你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: