首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 开发语言 > C++ >

阿 这样的有关问题也有实在的想不通阿

2012-02-15 
请高手看看阿 这样的问题也有实在的想不通阿请看看才这几句代码就出错了 错误1fatalerrorC1083:Cannotopen

请高手看看阿 这样的问题也有实在的想不通阿
请看看才这几句代码就出错了 
错误1fatal   error   C1083:   Cannot   open   include   file:   'iostream.h ':   No   such   file   or   directorye:\zhangmeiproject\zmvc\point\point\point.cpp1


#include   <iostream.h>

struct   Point
{
int   x;
int   y;
};
void   main()
{
Point   pt;
pt.x   =   5;
pt.y   =   5;
cout < <pt.x < <endl;
}

请问这是什么原因?要如何解决呢?

[解决办法]
#include <iostream>

using namespace std;

struct Point
{
int x;
int y;
};
int main() // 不要用void 返回,标准不容许~
{
Point pt;
pt.x = 5;
pt.y = 5;
cout < <pt.x < <endl;
return 0;
}


#include <iostream>

struct Point
{
int x;
int y;
};
int main() // 不要用void 返回,标准不容许~
{
Point pt;
pt.x = 5;
pt.y = 5;
std::cout < <pt.x < <std::endl;
return 0;
}

两个试试~

热点排行