fork download
  1. #include <stdio.h>
  2.  
  3.  
  4. int isTriang(int a, int b, int c) {
  5.  
  6. if ((a + b) > c && (a + c) > b && (b + c) < a) {
  7. return 1;
  8. } else {
  9. return 0;
  10. }
  11. }
  12.  
  13. int main() {
  14. if (isTriang(12, 20, 7)) {
  15. printf("삼각형이 됩니다.");
  16. } else {
  17. printf("삼각형이 안됩니다.");
  18. }
  19.  
  20. return 0;
  21. }
Success #stdin #stdout 0.01s 5320KB
stdin
Standard input is empty
stdout
삼각형이 안됩니다.