fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. int arr[] = { 4, 5, 6, 7 };
  6. int* p = (arr + 1); // Pointer p points to the second element of arr
  7. cout << *(arr+1) + 10; // Dereferencing arr (points to arr[0]) and adding 10
  8. return 0;
  9. }
  10.  
Success #stdin #stdout 0s 5256KB
stdin
Standard input is empty
stdout
15