I am new to the pointer in c, I have done the following simple array programme using the pointer.
#include<stdio.h>
void disp(int *);
void show(int a);
int main()
{
int i;
int marks[]={55,65,75,56,78,78,90};
for(i=0;i<7;i++)
disp(&marks[i]);
return 0;
}
void disp(int *n)
{
show((int) &n);
}
void show(int a)
{
printf("%d",*(&a));
}
I want to get all these values that are stored in the array as output but I only get the memory number of these stored value in the array. plz, help me how to get the array values as output.