fork(1) download
  1. #include <stdexcept>
  2. #include <iostream>
  3.  
  4. int main(){
  5. try {
  6. throw std::logic_error{"Whoops"};
  7. }
  8. catch (const std::exception& ex) {
  9. std::cout << ex.what() << std::endl;
  10. }
  11. }
Success #stdin #stdout 0s 3472KB
stdin
Standard input is empty
stdout
Whoops