Kahelm
4 год назад
памагите плиз дам высокие баллы
ОТВЕТЫ
Boris
Oct 24, 2020
#include <iostream>
#include <cmath>
using namespace std;
int main() {
int a, b, c;
cin >> a >> b >> c;
double p = (a + b + c) / 2;
double s = sqrt(p * (p - a) * (p - b) * (p - c));
cout << s;
}
using System;
using System.Collections.Generic;
namespace Program
{
class main
{
static int getNum()
{
return Convert.ToInt32(Console.ReadLine());
}
public static void Main(string[] args)
{
int a = getNum();
int b = getNum();
int c = getNum();
double p = (a + b + c / 2);
double s = (Math.Sqrt(p * (p - a) * (p - b) * (p - c)));
Console.Write(s);
}
}
}
420