what are the advantage and disadvantage of recursion

Answer Posted / jyoti singh

Advantages of recursion:-
1.Recursion is more efficient if the program using recursion is run on computer with multiprocessing facilities.
2.It is very useful in solving the data structure problems.
3. It is easily, simple and understandable.

Disadvantages of recursion:-
1. It requires more memory because recursive calls along with automatic variables are stored on the stack.
2.The computer may run out of memory if recursive calls are not properly checked.

Is This Answer Correct ?    15 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the use of printf() and scanf() functions?

850


What are the rules for identifiers in c?

836


What is character constants?

916


How do I use strcmp?

844


What is an lvalue in c?

909


Write the syntax and purpose of a switch statement in C.

870


What is methods in c?

844


Is it possible to use curly brackets ({}) to enclose single line code in c program?

1073


Is c dynamically typed?

908


Explain can the sizeof operator be used to tell the size of an array passed to a function?

820


Which operators cannot be overloaded a) Sizeof b) .* c) :: d) all of the above

925


Iam a B.Tech graduate and completed my engineering in 2009, from 2005 to 2009 and after that i had done nothing.Now i want to do job and get into BPO field . Friends give me suggestions as what to say in interview... if they ask me that what would you had done ... these many years without doing job ??????? pls urgent

1649


How do you list a file’s date and time?

834


Do character constants represent numerical values?

1091


Describe explain how arrays can be passed to a user defined function

865