To perform recursion which data structures is used

To perform recursion which data structures is used?

E

Expert

Verified

To perform recursion we use stack. As it use LIFO (Last In First Out) property which remembers its 'caller' hence it knows whom to return the value and when the function has to return. Recursion use system stack for storing the return addresses of the function calls.

Every recursive function has its corresponding iterative (non-recursive) function. Still when such equivalent iterative processes are written, explicit stack is used.

   Related Questions in Database Management System

©TutorsGlobe All rights reserved 2022-2023.