#include <iostream> #include <sstream> #include <stdio.h> #include <string> #include <math.h> #include <algorithm> #include <stdlib.h> #include <stack> #include <map> #include <set> #include <queue> using namespace std; int main() { #ifdef ONLINE_JUDGE #else freopen("1.txt","r",stdin); #endif int a,b,c; while(cin>>a) { cin>>b>>c; double p=(a+b+c)*1.0/2; double ans=sqrt(p*(p-a)*(p-b)*(p-c)); printf("%.2lf",ans); } return 0; } |
Double click to view unformatted code.