Question: 2. Consider this code: int a = 9; int func() { return a; main() { int a = 7; int b; b = func();
2. Consider this code: int a = 9; int func() { return a; main() { int a = 7; int b; b = func(); a. What value gets assigned to b if static scoping of a is in effect? b. What value gets assigned to b if dynamic scoping of a is in effect?
Step by Step Solution
3.47 Rating (147 Votes )
There are 3 Steps involved in it
The code presented in the image appears to be in C or a similar language and it is designed to illus... View full answer
Get step-by-step solutions from verified subject matter experts
