VC++6.0连接出现以下错误?
初用VC,写一个简单程序:main()
{
printf("hello");
getch();
}
编译成功,0 error ,0 warning
但连接时如下错误:
Linking...
Stack.obj : error LNK2005: _main already defined in Queue.obj
a.obj : error LNK2005: _main already defined in Queue.obj
Queue.obj : error LNK2001: unresolved external symbol _Outqueue
Debug/风雨扁舟.exe : fatal error LNK1120: 1 unresolved externals
执行 link.exe 时出错.
1 error(s), 0 warning(s)
为什么会这样?谢谢!