fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main()
  5. {
  6. if(nullptr == 0)
  7. cout << "This will print" << endl;
  8.  
  9. int* ptr = nullptr;
  10. if(ptr == 0)
  11. cout << "This will also print" << endl;
  12.  
  13. if(ptr == nullptr)
  14. cout << "So will this" << endl;
  15.  
  16. return 0;
  17. }
Success #stdin #stdout 0s 3140KB
stdin
Standard input is empty
stdout
This will print
This will also print
So will this