what are the advantage and disadvantage of recursion
Answer Posted / vadivelt
Recursion will be useful when same kind of job has to be
continued for a finite no input or time.
Eg: calculating series, finding factorial etc..
Disadvantage would be,
1.Hard to analyse or understand the code.
2.If the recursive function is called for infinite no of
times and memory constrains are not taken care, then stack
overflow may occur So system may crash.
| Is This Answer Correct ? | 52 Yes | 7 No |
Post New Answer View All Answers
Do you know the difference between exit() and _exit() function in c?
What are the __date__ and __time__ preprocessor commands?
What is 02d in c?
What are local static variables? How can you use them?
What is the difference between array_name and &array_name?
Why is structure important for a child?
Can we declare variable anywhere in c?
Hai what is the different types of versions and their differences
What is volatile keyword in c?
What are formal parameters?
What is the difference between %d and %i?
What is a #include preprocessor?
What is operator promotion?
Did c have any year 2000 problems?
Explain how can I prevent another program from modifying part of a file that I am modifying?