fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. struct X {
  5. X operator++(int) { cout << "++\n"; return *this; }
  6. bool operator < (int) { cout << "<\n"; return false; }
  7. };
  8.  
  9. int main() {
  10. // your code goes here
  11.  
  12. X x;
  13. while (x++ < 10);
  14. return 0;
  15. }
Success #stdin #stdout 0s 3140KB
stdin
Standard input is empty
stdout
++
<