Friday, October 30, 2020

C program of exam results

 #include <stdio.h>

int main() {

    float e,m,s,t,a;

    printf("Enter English,Maths,Science marks:");

    scanf("%f %f %f",&e,&m,&s);

    t=e+m+s;

    a=t/3;

    if(e>=35 && m>=35 && s>=35)

    {

        if(a>=70)

            printf("Distinction");

        else if(a>=60)

            printf("First Class");

        else if(a>=50)

            printf("Second Class");

        else

            printf("Pass Class");

    }

    else

        printf("Fail");

}

No comments:

Post a Comment

What If They Misunderstood You? ❤️ | How I Handle Misunderstandings

https://youtube.com/shorts/I09jcicjGnA   Right. [clears throat] So I want to share that over the time I have realized that you there is a hi...