Home > Back-end >  Find a scope
Find a scope

Time:09-27

Estimate the great god knows, but beginners can read know function statement in the body only valid within the function, and under special circumstances, some of the statements are effective only within a certain range, such as:
For (int I=0;; ) {; }; Do {int I=0} while (); While (1) {int I=0}; Out of the loop body I is a definition; Further the if (1) {int I=0; } the curly braces is invalid; Switch beyond constant-like case (untested) in variables defined within certain range out of the range is invalid; Even {int I=0}; The curly braces is invalid,

CodePudding user response:

This is called a block scope
  • Related