sort by best latest
int n, i,array,s=0;
printf("Enter no. of students");
printf("Enter the marks of students one by one");
You can help the HubPages community highlight top quality content by ranking this answer up or down.
only showing the basics , its an alternative which dosen't waste memory space much .
printf("how many students in the class:");
Set up a loop; if you know how many students, you can do a for loop, otherwise do a while loop and use a score of -1 to end the loop.
Then add up all the scores and divide by the number of scores. You'll want to make sure at least one score was input to avoid a divide by 0 error.
Copyright © 2017 HubPages Inc. and respective owners. Other product and company names shown may be trademarks of their respective owners. HubPages® is a registered Service Mark of HubPages, Inc. HubPages and Hubbers (authors) may earn revenue on this page based on affiliate relationships and advertisements with partners including Amazon, Google, and others.
Copyright © 2017 HubPages Inc. and respective owners.