You might try, instead of trying to use the deprecated version of iostream.h, to do something like this: #include <iostream> using namespace std; int i=2; static int si; const int ci=2; struct { int i,j;} s={21,22}; int main(void) { int j=11; cout << s.j; return 0; } Also, make sure that you compile with g++, not gcc.... Wayne Keen