Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

write a program to find the sum of the array elements in c
language?

Answer Posted / uday

#include<stdio.h>
void main()
{
int a[i],sum=0;
printf("enter n value");
scanf("%d",&n);
for(i=0;i<n,i++)
{
scanf("%d",&a[i])
}
for(i=0;i<n;i++)
{
sum=sum+a[i];
}
printf("sum=%d");
}

Is This Answer Correct ?    2 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

i got 75% in all semester am i eligible for your company

2173


How can variables be characterized?

2131


What are the standard predefined macros?

1070


Write a program to reverse a linked list in c.

1068


Explain how do you override a defined macro?

1021


Why we use stdio h in c?

987


What is the difference between strcpy() and memcpy() function in c programming?

1030


If I have a char * variable pointing to the name of a function ..

1117


application attempts to perform an operation?

1918


What is structure pointer in c?

991


What is a scope resolution operator in c?

1209


What is meant by keywords in c?

1038


what is recursion in C

1023


What is bubble sort in c?

1005


write a program for the normal snake games find in most of the mobiles.

2219