by Dinesh Thakur

Tail recursion occurring when the recursive call is at the end of the recursive instruction. This eliminates the potential problem of stack overflow. A call is tail recursive if nothing has to be done after the call returns. i.e. when the call returns, the returned value is immediately returned from the calling method.