Function S(a,b,c:real):real;
Var
p:real;
Begin
p:=(a+b+c)/2;
result:=Sqrt(p*(p-a)*(p-b)*(p-c))
End;
Var
a,b,c:real;
Begin
Write('a = ');ReadLn(a);
Write('b = ');ReadLn(b);
Write('c = ');ReadLn(c);
if (aelse WriteLn('Треугольник не существует')
End.
Пример:
a = 3
b = 4
c = 5
S = 6