program DIEN_TICH_HINH_TAM_GIAC;
Uses crt;
var a, b, c: integer;
var p, s: real;
begin
CLRSCR;
write ('nhap a: ');
readln (a);
write ('nhap b: ');
readln (b);
write ('nhap c: ');
readln (c);
p:=0;
s:=0;
if (a+b > c) and (b+c > a) and (a+c > b) then
begin
p:=(a+b+c)/2;
s:=sqrt(p*(p-a)*(p-b)*(p-c));
textcolor (YELLOW);
writeln ('dien tich cua tam giac la: ',s);
delay (500);
textcolor (lightblue);
writeln ('===============THE END===============');
readln;
end
Else
begin
textcolor (lightred);
writeln ('BA CANH NAY KHONG THE TAO THANH 1 TAM GIAC');
DELAY (1000);
textcolor (green+blink);
WRITELN ('VUI LONG CHAY LAI CHUONG TRINH !!!');
READLN;
end;
END.