fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. int a = 5;
  6. int b = 10;
  7. int *r = &a;
  8. cout << *r << endl;
  9. r = &b;
  10. cout << *r << endl;
  11. }
  12.  
  13. //https://pt.stackoverflow.com/q/85700/101
Success #stdin #stdout 0s 4512KB
stdin
Standard input is empty
stdout
5
10