Tail Recursion in Scala

Recursion and Tail Recursion in Scala

Reading Time: 4 minutes Introduction: Recursion is quite common in the programming world. If you don’t know recursion, it means, solving a problem by breaking it into smaller sub-problems until you solve it trivially. You can easily spot recursion if you see a method calling itself with a smaller subset of input. Recursion and immutability are corner zone of functional programming. As we have seen earlier, while using loops, Continue Reading

Recursion in scala in a simple way

Reading Time: 4 minutes What is Recursion? It is the technique of making a function call itself directly or indirectly and the corresponding function is called a recursive function. This technique provides a way to break complicated problems down into simple problems which are easier to solve. Recursion may be a bit difficult to understand and it can take some time to get your head around how it works Continue Reading