fork(1) download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. char * ptr = "123";
  6.  
  7. ptr[1024]='5';
  8. ptr[1025]='6';
  9. ptr[1026]='7';
  10.  
  11. std::cout << ptr << std::endl;
  12. }
Runtime error #stdin #stdout 0s 3336KB
stdin
Standard input is empty
stdout
Standard output is empty