Question: Really need part 2 Programming Language Concepts Test 2 April 10, 2018 7. (12 points) 14. Consider the following program, written in JAVASCRIPT-LIKE syntax: //
Programming Language Concepts Test 2 April 10, 2018 7. (12 points) 14. Consider the following program, written in JAVASCRIPT-LIKE syntax: // main program var x, y. 2i function subl) var a, YZ function sub2) t var a, b, z: function sub3() var a, ,Wi Part1) Given the following calling sequences and assuming that dynamie scoping is used, what variables are visible during execution of the last subprogram activated? Include with each visible variable the name of the unit where it is declared. a. main calls subl; subl calls sub2; sub2 calls sub3. b. main calls subl; subl calls sub3. c. main calls sub2; sub2 calls sub3; sub3 calls subl. d. main calls sub3; sub3 calls subl. e. main calls subl; subl calls sub3; sub3 calls sub2. f. main calls sub3; sub3 calls sub2; sub2 calls subl Part2) Repeat Partl' with a static scoping
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
