Computer Science, asked by sijups425, 6 months ago

Please answer plzzzz write a subprogram to input any 3 numbers and determine which one is highest

Answers

Answered by sahil10august
1

#include<stdio.h>

int main()

{

int a,b,c;

printf("Enter three no.\n");

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

if(a>b)

{

if(a>c)

printf("%d is greater.",a);

else

printf("%d is greater.",c);

}

else

{

if(b>c)

printf("%d is greater.",b);

else

printf("%d is greater.",c);

}

return 0;

}

May be helpful for you

Sahil

Attachments:
Similar questions