Write the function prototype for a function called Average A
Solution
Function prototype is necessary in order to inform the compiler about the function before starting the main method.
Few Points:
Here\'s the program,
double averageAge(int,int,int) //this is function prototype
void main(){
printf(\"The average age of 20,30,50 is %f\",averageAge(20,30,50));
}
double averageAge(int a,int b,int c){ // this is function defination
return (a+b+c)/3;
}
