标示符命名

#include <iostream>
#include<iomanip>
using namespace std;
int main()
{

double _x=1;
cout<<setw(8)<<_x<<endl;
return 0;
}

 -------------

#include <iostream>
#include<iomanip>
using namespace std;
int main()
{

long _x=1;
cout<<setw(8)<<_x<<setw(8)<<sizeof(_x)<<endl;
return 0;
}

1 4
Press any key to continue

-----

#include <iostream>
#include<iomanip>
using namespace std;
int main()
{

short _x=1;
cout<<setw(8)<<_x<<setw(8)<<sizeof(_x)<<endl;
return 0;
}

----

1 2
Press any key to continue

posted @ 2011-11-24 18:46  贰百舞  阅读(106)  评论(0编辑  收藏  举报