fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. const int x = 5;
  6. int* p = const_cast<int*>(&x);
  7. *p = 10;
  8. return 0;
  9. }
Success #stdin #stdout 0s 3336KB
stdin
Standard input is empty
stdout
Standard output is empty