fork download
  1. #include <iostream>
  2. #include <map>
  3. using namespace std;
  4.  
  5. int main() {
  6.  
  7. std::map<std::string, size_t> mp = { { "test", 0 }, { "test2", 1 } };
  8.  
  9. auto it = mp.find(nullptr);
  10.  
  11. std::cout << (it == mp.end()) << std::endl;
  12.  
  13. return 0;
  14. }
Runtime error #stdin #stdout #stderr 0s 3472KB
stdin
Standard input is empty
stdout
Standard output is empty
stderr
terminate called after throwing an instance of 'std::logic_error'
  what():  basic_string::_S_construct null not valid