Monday, November 1, 2010

find the average of three float numbers-C

#include
#include
int main(void)
{
float a,b,c,avg=0;
clrscr();
printf("\n Enter the four floating point nos.\n");
scanf("%f%f%f",&a,&b,&c);
avg=(a+b+c)/3;
printf("\n the avarage is=%10.5f",avg);
getch();
return 0;
}

No comments:

Post a Comment