Tag : recursion

void function(int x){ if(x<=0) return; function(x–); } This is a recursion function which is called with the value of x = 20. The Recursive call will take place in this way function(20)…function(19)…….function(0) Each function call will use some memory and if the data is big it will throw StackOverflowException. So what I want to know ..

Read more