fork(3) download
  1. #include <stdio.h>
  2. #include <math.h>
  3.  
  4. int main (void) {
  5. int hip, cat1, cat2;
  6. scanf("%d", &cat1);
  7. scanf("%d", &cat2);
  8. scanf("%d", &hip);
  9. if (hip == (int)sqrt(pow(cat1,2) + pow(cat2,2))) {
  10. printf("SIM");
  11. } else {
  12. printf("NAO");
  13. }
  14. return 0;
  15. }
Success #stdin #stdout 0s 2012KB
stdin
3
3
4
stdout
SIM