#include <stdio.h>
#include <conio.h>

//Find average marks of 5 subjects - FScOnline.info

int main()
{
  int a,b,c,d,e,average;
  
  printf("Enter marks of subject 1: ");
  scanf("%d",&a);
  printf("Enter marks of subject 2: ");
  scanf("%d",&b);
  printf("Enter marks of subject 3: ");
  scanf("%d",&c);
  printf("Enter marks of subject 4: ");
  scanf("%d",&d);
  printf("Enter marks of subject 5: ");
  scanf("%d",&e);
  
  average=(a+b+c+d+e)/5;
  printf("\nAverage: %d",average);
  
  getch();
  return 0;
}

 Output

Share.

I'm a full-stack developer, specializing in the PHP, JS, Wordpress, MEAN Stack, MERN Stack & Django. I hold a high standard of quality in everything that I do.

Leave A Reply