C PROGRAM C program to find the grade of your mark using Else if ladder#include <stdio.h> #include<conio.h> void main() { int marks; clrscr(); printf("Enter your marks out of 100 \n"); scanf("%d",&marks); if(marks>=95) printf("the grade is S"); else if(marks>=90) printf("the grade is A"); else if(marks>=80) printf("the grade is C"); else if(marks>=70) printf("the grade is D"); else printf("the grade is F"); getch(); } OUTPUT : Enter your marks out of 100 96 the grade is S Process finished. |
No comments:
Post a Comment