[ create a new paste ] login | about

Link: http://codepad.org/NclLtkqB    [ raw code | output | fork ]

C++, pasted on Feb 8:
1
2
3
4
5
6
7
int main() {
  istringstream ss ("12");
  int n;
  ss >> n;
  cout << "eof():  " << ss.eof() << '\n';
  cout << "fail(): " << ss.fail() << '\n';
}


Output:
1
2
eof():  true
fail(): false


Create a new paste based on this one


Comments: