Run ID 作者 问题 语言 测评结果 分数 时间 内存 代码长度 提交时间
130038 刘嘉柚 海伦公式 C++ 通过 100 0 MS 248 KB 356 2024-01-27 15:28:07

Tests(2/2):


#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; }


测评信息: