#include <stdio.h>
int main() {
float a, b, c;
float a2, b2, c2;
printf("Introduce los tres lados del triangulo: ");
scanf("%f %f %f", &a, &b, &c);
a2 = a * a;
b2 = b * b;
c2 = c * c;
if (a2 == b2 + c2 || b2 == a2 + c2 || c2 == a2 + b2) {
printf("\nEl triangulo es RECTANGULO.\n");
}
else if (a2 > b2 + c2 || b2 > a2 + c2 || c2 > a2 + b2) {
printf("\nEl triangulo es OBTUSANGULO.\n");
}
else {
printf("\nEl triangulo es ACUTANGULO.\n");
}
return 0;
}
To embed this project on your website, copy the following code and paste it into your website's HTML: