#include "stdafx.h"
#include <iostream>
using namespace std;
int a=10;
void main()
{
a=20;
cout<<a<<endl;
cout<<::a<<endl;
}
output: 20
20
I actually want the "cout<<::a<<endl"
output 10, but failed. Does "::a" mean a is in the gloable scope?
What should I have to change the code to make the second ouput 10 ? using "::a"