Start learning 50% faster. Sign in now
A stack is the most suitable data structure for implementing recursion. This is because recursive calls need to store the state of the current function execution before jumping into the next function call. Stacks follow the Last In, First Out (LIFO) principle, which perfectly suits the recursive function call structure. Why Other Options are Wrong: b) A queue follows First In, First Out (FIFO), which doesn’t support the nature of recursion. c) Linked lists can be used for dynamic memory but are not suitable for managing function calls in recursion. d) Arrays have a fixed size and do not inherently support LIFO behavior. e) Hash tables are for storing key-value pairs and have no role in recursion.
How many persons are having costlier bike than R?
How many persons are celebrating between F and the one who works in Tech Mahindra?
Who lives in flat 1 of the bottommost floor?
O uses which of the following car?
What is the direction of P’s flat with respect to C’s flat?
Three persons work in which of the following shifts?
Which of the following statements is/are not true?
Which of the following ice cream was placed at box 5?
How many boxes are kept below of box R?
How many floors are between F and K?