Write A Program Of Sum of Ten Number Through Function:
#include<stdio.h>
#include<conio.h>
int mul(int );//function prototype
int main()
{
int a,sum=0;
printf("enter the value of a\n");
for(a=1;a<=10;a++){
// printf("%d\n",mul(a));
sum=sum+a;
}
printf("sum is%d", mul(sum));// function call which can pass the value to function definition
getch();
}
int mul(int x)// function definition
{
return x;
}