Thanks for the helpful replies
#include <stdio.h>
#include <stdlib.h>
int funcAverage( int x, int y, int z ){
double sumTotal, average;
sumTotal = x + y + z;
average = sumTotal / 3;
return average;
}
main(){
int value1 = 9, value2 = 5 , value3 = 12, average1;
average1 = funcAverage( value1, value2, value3 );
printf("\nThe first average is: %.4lf\n\n", average1);
system("pause");
}
This post has been edited by sf18: 23 February 2010 - 02:24 PM

New Topic/Question
Reply




MultiQuote




|