|
A short program is as follows
int _tmain (int argc, _TCHAR * argv [])
{
char p [10];
char t [10] = "111111111";
char t1;
cout << t;
cin.getline (p, 4);
cout << p << endl;
int a;
cout << "here" << endl;
cin >> t;
cout << "here";
cout << t << endl;
}
Enter iloveyou
Shows as follows:
111111111iloveyou
ilo
here
here
Please press any key to continue ...
Question:
Why t output is (nothing (spaces or tabs or ...))
I think cout << t << endl; this sentence is definitely executed, at least endl has been output, then the content of my t, I can not see. Thank you very much! |
|