fork(2) download
  1. #include <iostream>
  2. #include <string>
  3. using namespace std;
  4.  
  5. int main() {
  6. string s = "0xfffefffe";
  7. unsigned int x = stoul(s, nullptr, 16);
  8.  
  9. cout<< x << endl;
  10.  
  11. return 0;
  12. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
prog.cpp: In function 'int main()':
prog.cpp:7:31: error: 'nullptr' was not declared in this scope
     unsigned int x = stoul(s, nullptr, 16);
                               ^
prog.cpp:7:42: error: 'stoul' was not declared in this scope
     unsigned int x = stoul(s, nullptr, 16);
                                          ^
stdout
Standard output is empty