#include<stdio.h>
int SumElement(int *,int);
void main(void)
{
int x[10];
int i=10;
for(;i;)
{
i--;
*(x+i)=i;
}
printf("%d",SumElement(x,10));
}
int SumElement(int array[],int size)
{
int i=0;
float sum=0;
for(;i<size;i++)
sum+=array[i];
return sum;
}
output?
Answer Posted / lusi dash
55
| Is This Answer Correct ? | 1 Yes | 2 No |
Post New Answer View All Answers
Explain what is the benefit of using const for declaring constants?
Did c have any year 2000 problems?
Compare and contrast compilers from interpreters.
I have written a pro*C program to fetch data from the cursor. where in i have used the concept of BULK FETCH.... each FETCH statement is taking lots of time to fetch specified number of rows at...
write a program to rearrange the array such way that all even elements should come first and next come odd
What is a pointer and how it is initialized?
What is meant by initialization and how we initialize a variable?
Write a program to use switch statement.
what type of questions arrive in interview over c programming?
please explain every phase in the "SDLC" in the dotnet.
What are the types of type qualifiers in c?
How do you convert a decimal number to its hexa-decimal equivalent.Give a C code to do the same
How do you convert strings to numbers in C?
Is c is a low level language?
What are the __date__ and __time__ preprocessor commands?