#include /*C program that takes as input an integer n, and then accepts as input n integer numbers. and prints their sum*/ int main() { int i,x, n; int sum = 0; printf("Enter the value of n : "); scanf("%d", &n); printf("Enter %d integers\n" , n); for ( i = 0 ; i< n; i++) { scanf("%d", &x); sum = sum + x; } printf("The sum of given %d numbers is %d.\n", n, sum); }