Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <stdlib.h>
- int main()
- {
- int a,b,c;
- printf("enter the numbers : \n");
- scanf("%d %d %d",&a,&b,&c);
- if(a==b)
- { if (b==c)
- printf("all the numbers are same");
- else printf("there is redundency");
- }
- else if(a!=b)
- {
- if(a==c)
- printf("there is redundency");
- else if(b==c)
- printf("there is redundency");
- else if(a>b)
- {
- if (a>c)
- printf("the largest number is %d\n",a);
- else if(c>b)
- printf("the largest number is %d\n",c);
- }
- else if (b>a)
- {
- if (b>c)
- printf("the largest number is %d\n",b);
- else if (c>b)
- printf("the largest number is %d\n",c);
- }
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement