新微赢技术网
标题:
【求助}怎么编译不通过
[打印本页]
作者:
^o^星禾じ☆v
时间:
2009-11-6 01:52
标题:
【求助}怎么编译不通过
# include <iostream>
int main()
{
using namespace std;
int* pt= new int;
*pt=1001;
cout<<"int";
cout<<"value="<<*pt<<":location="<<pt<<endl;
double* pd=new double ;
*pd=10000001.0;
cout<<"double";
cout<<"value="<<*pd<<":location="<<pd<<endl;
cout<<"size of pt="<<sizeof (pt);
cout<<"size of *pt="<<sizeof(*pt)<<endl;
cout<<"size of pd="<<sizeof pd;
cout<<"size of *pd="<<sizeof(*pd)<<endl;
return 0;
}
错误如下
Text2.cpp
D:\My Documents\Text2.cpp(4) : error C2018: unknown character '0xa3'
D:\My Documents\Text2.cpp(4) : error C2018: unknown character '0xbb'
D:\My Documents\Text2.cpp(5) : error C2144: syntax error : missing ';' before type 'int'
Text3.cpp
执行 cl.exe 时出错.
欢迎光临 新微赢技术网 (http://bbs.weiying.cn/)
Powered by Discuz! X3.2