scope rule notes

scope rule notes - variable" Example program...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
Scope Rule Tuesday, October 12, 2010 11:34 AM Has to do with where in a program a variables is active A variable is active in a program where it is declared to the end of the block in  which it was declared A variable which is declared in the same block it is used is called a "local 
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: variable" Example program Int x,y,z; f(intx) Int z; y(int y) 30. h(intx ,int z) 40. Int main() { 41. Int x; } Variable table Line # Global f g h Main 10 Y N Y N N...
View Full Document

Ask a homework question - tutors are online