fork download
  1. #include <iostream>
  2. using namespace std;
  3. int main()
  4. {
  5. int n[10];
  6. n[-1] = 5;
  7. n[-((long) &n)] = 100;
  8.  
  9. cout << n[-1] << endl;
  10. cout << n[-((long) &n)] << endl;
  11. }
Success #stdin #stdout 0s 3140KB
stdin
Standard input is empty
stdout
5
100