How can I understand this recursion example in Scala?

前端 未结 0 604
小鲜肉
小鲜肉 2020-12-17 07:20

I have the following method in Scala which uses recursion:

def foldLeft[Result](initial:Result, op:(Result, Elem) => Result) : Result = {
   if (isEmpty)
          


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题