What is the data structures used to perform recursion?
Answer / phool chand
Stack. Because of its LIFO (Last In First Out) property it remembers its ‘caller’ so knows whom to return when the function has to return. Recursion makes use of system stack for storing the return addresses of the function calls. Every recursive function has its equivalent iterative (non-recursive) function. Even when such equivalent iterative procedures are written, explicit stack is to be used.
Is This Answer Correct ? | 0 Yes | 0 No |
What is the use of placement new?
Can we use any class as map key?
What is the difference between collection and collections?
Define quadratic probing?
Explain what is linear search?
What do you mean by data and data structure?
Which is faster hashset or treeset?
Explain what is the data structures used to perform recursion?
How do you sort an array by value?
What is bubble insertion selection sort?
Draw a binary Tree for the expression : A * B - (C + D) * (P / Q)
Can we add duplicate keys in a hashmap?