哪位高手帮忙看看这段程序是哪出问题了?

#include<iostream>intmian(){std::cout<<"hellothere!\n";std::cout<<"Hereis5:"<<5<<"\n"... #include <iostream>
int mian()
{
std::cout<<"hello there!\n";
std::cout<<"Here is 5:"<<5<<"\n";
std::cout<<"The manipulator std::end1";
std::cout<<"wtites a new line to the screen.";
std::cout<<std::end1;
std::cout<<"Here is a very big number:\t"<<70000;
std::cout<<std::end1;
std::cout<<"Here is the sum of 8and 5:\t";
std::cout<<8+5<<std::end1;
std::cout<<"here's a fraction:\t\t";
std::cout<<(float)5/8<<std::end1;
std::cout<<"And a very very big number:\t";
std::cout<<(double)7000*7000<<std::end1;
std::cout<<"Don't forget to replace jesse Liberty";
std::cout<<"with yuor name...\n";
std::cout<<"Jesse Liberty is a C++ programmer!\n";
return 0;
}

出错信息
ompiling...
stade up.cpp
h:\c++\stade up.cpp(9) : error C2039: 'end1' : is not a member of 'std'
h:\c++\stade up.cpp(9) : error C2065: 'end1' : undeclared identifier
h:\c++\stade up.cpp(11) : error C2039: 'end1' : is not a member of 'std'
h:\c++\stade up.cpp(13) : error C2039: 'end1' : is not a member of 'std'
h:\c++\stade up.cpp(15) : error C2039: 'end1' : is not a member of 'std'
h:\c++\stade up.cpp(17) : error C2039: 'end1' : is not a member of 'std'
执行 cl.exe 时出错.

stade up.obj - 1 error(s), 0 warning(s)
展开
 我来答
豆恋凝爱0e
2009-08-28 · TA获得超过328个赞
知道小有建树答主
回答量:364
采纳率:0%
帮助的人:237万
展开全部
出错原因是,那个是endl(小写L),不是end1!
还有:不用每句输出语句语句前面都加上std::
直接在#include <iostream>下面加上一句using namespace std;就行
#include <iostream>
using namespace std;
int main()
{
cout<<"hello there!\n";
cout<<"Here is 5:"<<5<<"\n";
cout<<"The manipulator std::endl";
cout<<"wtites a new line to the screen.";
cout<<endl;
cout<<"Here is a very big number:\t"<<70000;
cout<<endl;
cout<<"Here is the sum of 8and 5:\t";
cout<<8+5<<endl;
cout<<"here's a fraction:\t\t";
cout<<(float)5/8<<endl;
cout<<"And a very very big number:\t";
cout<<(double)7000*7000<<endl;
cout<<"Don't forget to replace jesse Liberty";
cout<<"with yuor name...\n";
cout<<"Jesse Liberty is a C++ programmer!\n";
return 0;
}
推荐律师服务: 若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询

为你推荐:

下载百度知道APP,抢鲜体验
使用百度知道APP,立即抢鲜体验。你的手机镜头里或许有别人想知道的答案。
扫描二维码下载
×

类别

我们会通过消息、邮箱等方式尽快将举报结果通知您。

说明

0/200

提交
取消

辅 助

模 式