#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 / mannucse
55
| Is This Answer Correct ? | 3 Yes | 2 No |
Post New Answer View All Answers
Write a client and server program in C language using UDP, where client program interact with the Server as given below: i) The client begins by sending a request to send a string of 8 characters or series of 7 numbers, the server sends back a characters or numbers as per the request of the client. ii) In case of series of 7 numbers: The client sends a multiplication of numbers, to the server. iii) In case of a string of 8 characters: The client sends a reverse order of string to the server.. iv) Server will send an acknowledgment to the client after receiving the correct answer
A routine usually part of the operation system that loads a program into memory prior to execution a) linker b) loader c) preprocessor d) compiler
Why is c faster?
Why is c so powerful?
what is associativity explain what is the precidence for * and & , * and ++ how the folloing declaration work 1) *&p; 2) *p++;
What are header files and explain what are its uses in c programming?
How pointers are declared?
A character flag or control mechanism that delineates one data item from another a) variable b) constant c) delimiter d) call by reference
Write a program to input the price of 1 burger and the number of burgers eaten by a group of friends .print the total amount to be paid by the group?
Describe explain how arrays can be passed to a user defined function
What is c language and why we use it?
What's a good way to check for "close enough" floating-point equality?
How can I pad a string to a known length?
Which one would you prefer - a macro or a function?
Explain the use of function toupper() with and example code?