Untitled
unknown
plain_text
2 years ago
334 B
7
Indexable
#include <stdio.h>
#include<stdlib.h>
int main()
{
long long int n,sum=0;
scanf("%lld",&n);
long long int a[n];
for (int i = 0; i < n; i++)
{
scanf("%lld",&a[i]);
}
for (int i = 0; i < n; i++)
{
sum=sum+a[i];
}
printf("%lld\n",abs(sum));
return 0;
}
Editor is loading...