Tham khảo:
program tam_giac;
uses crt;
var a,b,c,p,S:real;
begin
clrscr;
write('nhap canh a:'); readln(a);
write('nhap canh b:'); readln(b);
write('nhap canh c:'); readln(c);
p:=(a+b+c)/2;
S:=(p*(p-a)*(p-b)*(p-c));
writeln('dien tich hinh tam giac la:',S:10:2);
readln;
end.