C++ examples for Function:Function Creation
Program with multiple local variables called i.
#include <iostream> using namespace std; int main()//from ww w . ja v a 2 s . c om { int i; i = 10; { int i; i = 20; cout << i << " " << i << "\n"; { int i; i = 30; cout << i << " " << i << " " << i << "\n"; } } cout << i << " " << i << " " << i << "\n"; return 0; }