c++编译出现的问题

dabeixin 2006-12-23 05:53:47
代码如下
#include "stdafx.h"
#include <iostream>





int _tmain(int argc, _TCHAR* argv[])
{
cout << "testing 1, 2, 3\n";
return 0;
}

在Microsoft Visual Studio 2005中编译出现问题:
“cout”: 未声明的标识符
到底是啥回事?

另外,我刚学习c++,以前没有学过windows的东西,接触的都是命令行之类的东西.Microsoft Visual Studio 2005在编译上有怎样的特点呢?请多多指点,谢谢
...全文
106 4 打赏 收藏 转发到动态 举报
写回复
用AI写文章
4 条回复
切换为时间正序
请发表友善的回复…
发表回复
scorpio16 2006-12-23
  • 打赏
  • 举报
回复
用std::cout代替cout
jixingzhong 2006-12-23
  • 打赏
  • 举报
回复
#include<iostream.h>
caocheng8230 2006-12-23
  • 打赏
  • 举报
回复

using namespace std;
或者using std::cout;

或者#include<iostream.h>
healer_kx 2006-12-23
  • 打赏
  • 举报
回复
using namespace std;

64,637

社区成员

发帖
与我相关
我的任务
社区描述
C++ 语言相关问题讨论,技术干货分享,前沿动态等
c++ 技术论坛(原bbs)
社区管理员
  • C++ 语言社区
  • encoderlee
  • paschen
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
  1. 请不要发布与C++技术无关的贴子
  2. 请不要发布与技术无关的招聘、广告的帖子
  3. 请尽可能的描述清楚你的问题,如果涉及到代码请尽可能的格式化一下

试试用AI创作助手写篇文章吧