program in c sum N numbers of an array using pointers
Answers
Answered by
0
Answer:
* C program to read N integers and store them in an array A.
* Find the sum of all these elements using pointer.
#include <malloc.h>
int i, n, sum = 0;
int *a;
printf("Enter the size of array A \n");
scanf("%d", &n);
a = (int *) malloc(n * sizeof(int));
Explanation:
Thank you
Similar questions