正确题解,直接开写!
2024-11-05 21:27:32
发布于:广东
11阅读
0回复
0点赞
#include <iostream>
#include <cstdio>
#include <cmath>
using namespace std;
double S (double a, double b, double c){
double p = (a + b + c)/2;
p = sqrt(p * (p - a) * (p - b) * (p - c));
return p;
}
int main ()
{
double a, b, c;
cin >> a >> b >> c;
double p = S (a, b, c);
printf("%.2f", p);
return 0;
}
这里空空如也
有帮助,赞一个