fork(1) download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. // your code goes here
  6. int i = 0, * const j = &i;
  7.  
  8. std::cout << "i = " << i << ", *j = " << *j << std::endl;
  9.  
  10. i = 7;
  11.  
  12. std::cout << "i = " << i << ", *j = " << *j << std::endl;
  13.  
  14. return 0;
  15. }
Success #stdin #stdout 0s 3340KB
stdin
Standard input is empty
stdout
i = 0, *j = 0
i = 7, *j = 7