一个简单的问题 关于VC++6.0的 在线等啊
我刚装的 VC++6.0 以前一直用VS
但是输入了一些简单的代码后 出现
D:\My Documents\C++\Cpp1.cpp(13) : error C2676: binary '<<' : 'class std::basic_istream<char,struct std::char_traits<char> >' does not define this operator or a conversion to a type acceptable to the predefined operator
D:\My Documents\C++\Cpp1.cpp(14) : error C2676: binary '<<' : 'class std::basic_istream<char,struct std::char_traits<char> >' does not define this operator or a conversion to a type acceptable to the predefined operator
我输入的代码如下
#include<iostream>
using namespace std;
int add(int a,int b)
{
return a+b;
}
int main()
{
cout<<"hello entre your program world"<<endl;
int a=1,b=1;
cin<<a<<endl;
cin<<b<<endl;
cout<<add(a,b)<<endl;
return 0;
}
是不是现在的 CIN 不能用了 或者 头文件变了啊???