Header Ads Widget

Responsive Advertisement

Three digits find out the maximum number

#include<stdio.h>

int main ()

{

    int a,b,c;

    printf("Enter the value of a\n :");

    printf("Enter the value of b\n :");

    printf("Enter the value of c\n :");

    

    scanf("%d%d%d",&a,&b,&c);

    if(a>b)

    {

        if(a>c)

        {

            printf("a");

        }

    else

        {

            printf("c");

        }

    }

    else

    {

        if(b>c)

        {

            printf("b");

        }

    else

        {

            printf("c");

        }

    }

    return 0;

}


Post a Comment

0 Comments