Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save gs-niteesh/5fd4f6db2006021722a12ab5df0adcda to your computer and use it in GitHub Desktop.
Save gs-niteesh/5fd4f6db2006021722a12ab5df0adcda to your computer and use it in GitHub Desktop.
// program for average sum
#include <stdio.h>
int main()
{
char name;
scanf("%c", &name);
int m1;
int m2;
int m3;
scanf("\n%d %d %d", &m1, &m2, &m3);
printf("%c\n", name);
int avg = (m1 + m2 + m3) / 3;
printf("%d\n", avg);
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment