#include <stdio.h> #include <math.h> int main() { float a,b,c; scanf("%f %f %f",&a,&b,&c); float per,are,temp; per = a+b+c; temp = per/2; are = sqrt(temp*(temp-a)*(temp-b)*(temp-c)); printf("circumference=%.2f area=%.2f",per,are); return 0; }
忘记了已知三边求面积的公式