CSC 141 / CLASS 10 / INTERACTIVE
Where does a variable live?
Step through the four programs from Class 10 one line at a time. Every function call gets its own box, called a frame. Watch which box each variable goes into, and watch the box disappear when the function returns. Pick a variable name above the code to shade its scope, the lines where that name can be used.
Call with: