Category "tail-recursion"

Understanding how this recursive method works [duplicate]

Can someone please explain how this method works? I tried adding System.out.print statements but it didn't get me anywhere and I simply cannot

Understanding how this recursive method works [duplicate]

Can someone please explain how this method works? I tried adding System.out.print statements but it didn't get me anywhere and I simply cannot

scala string Tail recursion with pattern match

I am trying to write a tail recursion function to reverse string, here is the code, some reason I am not sure if the pattern match condition is preventing it fr