fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. for(int i = 0; i < 10; ++i) {
  6. int *c;
  7. if (i % 2 == 0) {int a; c = &(++a);}
  8. else {int b; c = &(++b);}
  9. cout << *c << ' ' << c << "alsdkfj;" << '\n';
  10. }
  11. return 0;
  12. }
Success #stdin #stdout 0s 5320KB
stdin
Standard input is empty
stdout
-1171981160 0x7fffba24fb70alsdkfj;
32767 0x7fffba24fb74alsdkfj;
-1171981160 0x7fffba24fb70alsdkfj;
32767 0x7fffba24fb74alsdkfj;
-1171981160 0x7fffba24fb70alsdkfj;
32767 0x7fffba24fb74alsdkfj;
-1171981160 0x7fffba24fb70alsdkfj;
32767 0x7fffba24fb74alsdkfj;
-1171981160 0x7fffba24fb70alsdkfj;
32767 0x7fffba24fb74alsdkfj;