roteil
یک شنبه 19 تیر 1390, 00:00 صبح
سلام من وقتی این برنامه را می نویسم با این error مواجه میشم
1>test string\test.cpp(8) : error C2679: binary '>>' : no operator found which takes a right-hand operand of type 'std::string' (or there is no acceptable conversion)
#include <iostream>
#include <conio.h>
#include <string.h>
using namespace std;
int main(){
string str;
cout<<"Enter a name :\n";
cin>>str;
cout<<str<<endl;
getch();
}
visual studio 2008
ممنون
1>test string\test.cpp(8) : error C2679: binary '>>' : no operator found which takes a right-hand operand of type 'std::string' (or there is no acceptable conversion)
#include <iostream>
#include <conio.h>
#include <string.h>
using namespace std;
int main(){
string str;
cout<<"Enter a name :\n";
cin>>str;
cout<<str<<endl;
getch();
}
visual studio 2008
ممنون