ENG  RUSTimus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

Common Board

Compilation Error on "cin >> s; //where s is string"
Posted by Aideen 19 Aug 2005 22:39
What's wrong with this:
###
#include <iostream>
using namespace std;
string s;
int main() {
cin >> s;
return 0;
}
###
I've toggled 'namespace std', 'iostream', 'string', '.h' and any other stuffs in my mind but it gets CE on operator >> of istream >> std:string.
what shall I do?
isn't judge using G++?

--Aidin.
Add this: #include <string> (-)
Posted by Problemset Maintainer 26 Aug 2005 09:38