Compile Error
foo.c: In function 'main': foo.c:3:9: error: 'A' undeclared (first use in this function) 3 | if (A + B > C && A + C > B && B + C > A) { | ^ foo.c:3:9: note: each undeclared identifier is reported only once for each function it appears in foo.c:3:13: error: 'B' undeclared (first use in this function) 3 | if (A + B > C && A + C > B && B + C > A) { | ^ foo.c:3:17: error: 'C' undeclared (first use in this function) 3 | if (A + B > C && A + C > B && B + C > A) { | ^
Code
#include <stdio.h>
int main(){
if (A + B > C && A + C > B && B + C > A) {
if (A == B && B == C) {
printf("Equilateral\n");
} else if (A == B || B == C || A == C) {
printf("Isosceles\n");
} else {
printf("Scalene\n");
}
} else {
printf("No Triangle\n");
}
}
Information
- Submit By
- Type
- Submission
- Problem
- P1108 Triangle Triangle Triangle!!!
- Contest
- Brain Booster #8
- Language
- C99 (GCC 13.2.0)
- Submit At
- 2025-02-17 15:08:48
- Judged At
- 2025-02-17 15:08:48
- Judged By
- Score
- 0
- Total Time
- 0ms
- Peak Memory
- 0 Bytes