Answer Posted / punam
Thank you all. This was helpful to me. So, to summarize all this should I say:
1. In C, we cannot define a function inside another function.
2. However, main() function is an exception as we can define another function inside a main() function. This can be called nesting of function inside main(). The inner function cannot be called from any outside function. It can be called only from main().
3. The only way to access the inner function from outside main() is by passing a function pointer of type inner function.
| Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
What is sizeof array in c?
List some of the static data structures in C?
What is use of pointer?
What is a 'null pointer assignment' error?
Why is main function so important?
Is null equal to 0 in sql?
What is the difference between memcpy and memmove?
how can i write a program that prints out a box such that whenever i press any key8(coordinate number) on the keyboard, the box moves.
How do you use a 'Local Block'?
How can I find out how much free space is available on disk?
What is 'bus error'?
Difference between Function to pointer and pointer to function
What are shell structures used for?
How is actual parameter different from the formal parameter?
What are comments and how do you insert it in a C program?