提交时间:2024-01-27 15:28:07
运行 ID: 130038
#include<bits/stdc++.h> #define ac double using namespace std; ac halen(ac x1,ac x2,ac x3){ ac p=(x1+x2+x3)/2; return sqrt(p*(p-x1)*(p-x2)*(p-x3)); } int main() { //freopen("year.in","r",stdin); //freopen("year.out","w",stdout); ac a,b,c; cin>>a>>b>>c; printf("area=%.2lf",halen(a,b,c)); //fclose(stdin);fclose(stdout); return 0; }