#include <stdio.h>
void main(){
int a[10] = { 5, 4, 9, 1, 10, 7, 8, 3, 2, 6 };
int i;
for ( i = 0 ; i < 10 ; i++ )
printf("%d ", a[i]);
}
|
#include <stdio.h>
void main(){
int a[10] = { 5, 4, 9, 1, 10, 7, 8, 3, 2, 6 };
int *p = a;
int *pend = a + 10;
for ( ; p < pend ; p++ )
printf("%d ", *p);
}
|