#include <stdio.h>
int main()
{
int*p,sum=0,i,a;
int x[5]={5,9,6,3,7};
i=0;
p=x;
printf("elements\t value\t addres\n\n");
while(i<5)
{
printf("a[%d]\t %d\t %u\n",i,*p,p);
sum=sum+*p;
i++,p++;
}
printf("\n sum=%d\n",sum);
printf("\n &x[0]=%u\n",&x[10]);
printf("\n p=%u\n",p);
return 0;
}
To embed this project on your website, copy the following code and paste it into your website's HTML: