Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <stdlib.h>
- int main()
- {
- int x,y,z,largest;
- x*=x;y*=y;z*=z;
- printf("Enter the three digits\n");
- scanf("%d %d %d\n",x,y,z);
- largest=x;
- if(y>largest){largest=y;
- printf("The three digits can form a right angled traingle\n")}
- else if(z>largest){largest=z;
- printf("The three digits can form a right angled traingle\n")}
- else{printf("The three digits can not form a right angled triangle\n"};
- return 0;
- }
Add Comment
Please, Sign In to add comment