SHOW:
|
|
- or go back to the newest paste.
| 1 | #include <stdio.h> | |
| 2 | ||
| 3 | int someArray[5] = {1,2,3,4,5};
| |
| 4 | - | typedef int** ppInt; |
| 4 | + | typedef int* pInt; |
| 5 | - | ppInt test = (ppInt)&someArray; |
| 5 | + | pInt test = (pInt)&someArray; |
| 6 | ||
| 7 | void putint(int a) { printf("%d ", a); }
| |
| 8 | ||
| 9 | - | for(i=0; i<5; i++) printf("%d ", test[i]); // Returns "1 2 3 4 5 "
|
| 9 | + | |
| 10 | int i; | |
| 11 | for(i=0; i<5; i++) putint(test[i]); // returns "1 2 3 4 5 " | |
| 12 | putchar('\n');
| |
| 13 | system("pause");
| |
| 14 | } |