write a C Program to find out the average of three numbers
/*Program to find out the average of three numbers*/
/*author:sai date:6-4-2015 */
#include<stdio.h>
int main()
{
int a,b,c;
float d;
printf("Enter Three numbers ");
scanf("%d%d%d",&a,&b,&c);
d=(a+b+c)/3;
printf("Average is = %f\ns",d);
}
output:
/*Program to find out the average of three numbers*/
/*author:sai date:6-4-2015 */
#include<stdio.h>
int main()
{
int a,b,c;
float d;
printf("Enter Three numbers ");
scanf("%d%d%d",&a,&b,&c);
d=(a+b+c)/3;
printf("Average is = %f\ns",d);
}
output:
No comments:
Post a Comment