I wrote this program to ask the user to give a series of grades of the students and then the program will compute the average grade of the student and also display if the student pass or fail using C programming language.
I am currently accepting programming work inventory system, enrollment system, accounting system, payroll system, information system, website design and development using WordPress, IT projects, school and application development, programming projects, thesis, and capstone projects, IT consulting work, computer tutorials, and web development work kindly contact me in the following email address for further details. If you want to advertise on my website kindly contact me also in my email address also. Thank you.
My email address is the following jakerpomperada@gmail.com, jakerpomperada@aol.com, and jakerpomperada@yahoo.com.My mobile number here in the Philippines is 09173084360. My telephone number at home here in Bacolod City, Negros Occidental Philippines is +63 (034) 4335675.
Here in Bacolod City, Negros Occidental I also accepting computer repair, web development using WordPress, Computer Networking, and Arduino Project development at a very affordable price. My personal website is http://www.jakerpomperada.comMy programming website is http://www.jakerpomperada.blogspot.comI am also a book author you can purchase my books on computer programming and information technology in the following links below.https://www.unlimitedbooksph.com/
Program Listing
/* average.c
Author : Jake Rodriguez Pomperada,BSCS,MAED-IT
Date : June 13, 2020 7:39 AM Saturday
Location : Bacolod City, Negros Occidental
Tool : Dev C++ Version 5.11
Website : http://www.jakerpomperada.com
Email : jakerpomperada@jakerpomperada.com and jakerpomperada@gmail.com
*/
#include <stdio.h>
int main() {
int numbers[5];
int a=0,solve=0,sum=0;
printf("\n\n");
printf("\tAverage Grade Solver Using C Language");
printf("\n\n");
for (a=0; a<=4; a+=1) {
printf("\tEnter Grade No. %d : ",a+1);
scanf("%d",&a[numbers]);
}
printf("\n\n");
for (a=0; a<=4; a+=1) {
sum = sum + a[numbers];
solve =( sum / 5);
}
printf("\tThe average grades is %d. ",solve);
printf("\n\n");
if (solve >=75) {
printf("\n");
printf("\tYou Passed the subject");
}
else {
printf("\n");
printf("\tYou Failed the subject");
}
printf("\n\n");
printf("\tEnd of Program");
printf("\n\n");
}
No comments:
Post a Comment