1)what are limitations for recursive function?
2)write a program to read a text file and count the number of characters in the text file
Answer / mubin ahmed shaik
Limitations of Recursive Approach:
1. Recursive solutions may involve extensive overhead because they use function calls. Each function call requires push of return memory address, parameters, returned result,etc. and every function return requires that many pops.
2. Each time you call a function you use up some of your memory allocation may be in stack or heap. If there are large number of recursive calls – then you may run out of memory.
| Is This Answer Correct ? | 15 Yes | 4 No |
What is bss in c?
Is sizeof a keyword in c?
Explain the differences between public, protected, private and internal.
what is the use of a array in c
What is the relationship between pointers and data structure?
What are the 5 types of inheritance in c ++?
Does * p ++ increment p or what it points to?
What is the translation phases used in c language?
Difference between fopen() and open()?
how to swap 2 numbers in a single statement?
How do you determine the length of a string value that was stored in a variable?
#include<stdio.h> main() { int a[3]; int *I; a[0]=100;a[1]=200;a[2]=300; I=a; Printf(“%d\n”, ++*I); Printf(“%d\n”, *++I); Printf(“%d\n”, (*I)--); Printf(“%d\n”, *I); } what is the o/p a. 101,200,200,199 b. 200,201,201,100 c. 101,200,199,199 d. 200,300