Answer to Question #38717 in C++ for Gaurav shukla
There is a concept of "scope" in the programming.
When you declare function2 inside of function1 like this
it can be accessed from function1 only as it was declared in its scope.
If you want to use function2 in other functions you will have to declare it in the global scope, like this:
I this case function1 and function2 can be accessed from any other function.
Need a fast expert's response?Submit order
and get a quick answer at the best price
for any assignment or question with DETAILED EXPLANATIONS!