fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5.  
  6. int a[3][3] = { 0, 1, 2, 3, 4, 5, 6, 7, 8 };
  7.  
  8. int (*x)[3] = &a[2];
  9.  
  10. for(int i=0;i<3; ++i)
  11. cout << (*x)[i] << endl;
  12.  
  13. //int* x[3] = &a[2];
  14.  
  15. return 0;
  16. }
Success #stdin #stdout 0s 3344KB
stdin
Standard input is empty
stdout
6
7
8