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

新手有关问题link出错

2012-02-07 
新手问题link出错#includeiostream.hstructPoint{intxinty}voidmain(){Pointptpt.x1pt.y1cout

新手问题link出错
#include   <iostream.h>
struct   Point
{
int   x;
int   y;
};

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

LIBCD.lib(wincrt0.obj)   :   error   LNK2001:   unresolved   external   symbol   _WinMain@16
Debug/Lesson2.exe   :   fatal   error   LNK1120:   1   unresolved   externals
执行   link.exe   时出错.
Lesson2.exe   -   1   error(s),   0   warning(s)

----------
怎么link出错呢

[解决办法]
工程建错了,应该建console工程。

热点排行