C Program to find Average of Five Subject

program:
#include<stdio.h>
int main()
{
 float a,b,c,d,e,avg;
 printf("Enter marks in Marathi: \n");
 scanf("%f",&a);
 printf("Enter marks in English: \n");
 scanf("%f",&b);
 printf("Enter marks in Hindi: \n");
 scanf("%f",&c);
 printf("Enter marks in Science:\n");
 scanf("%f",&d);
 printf("Enter marks in Maths: \n");
 scanf("%f",&e);
 avg=(a+b+c+d+e)/5;
 printf("Average of result=%f",avg);
return 0;
}
output:
Previous Post Next Post