rendered paste bodyprogram plotaj;
uses crt;
procedure staciakampis (a, b : real; var P : real);
begin
P:= a * b;
end;
procedure trikampis (c, h : real; var S : real);
begin
S:= 0.5 * c * h
end;
function trapecija (q, w, u : real) : real;
begin
trapecija:= ((q + w) / 2) * u;
end;
function rombas (t, r : real) : real;
begin
rombas:= (t * r) / 2;
end;
procedure langas (x1, y1, x2, y2, sp : integer);
begin
window (x1, y1, x2, y2);
textbackground(sp); clrscr
end;
var a, b, P, c, h, S, q, w, u, t, r : real;
begin
langas(2, 2, 30, 5, 2);
writeln ('A, tu Gyrdi Yvesk staciakampio krashtiniu');
read (a, b);
staciakampis (a, b, P);
langas(2, 7, 30, 9, 5);
writeln ('ploc:' ,P);
writeln ('o dabar trikampio krashtine ir aukstine');
read (c, h);
trikampis (c, h, S);
writeln ('plotynas:' ,S);
writeln('metas ivesti trapecijos pagrindus ir aukstine');
trapecija (q, w, u);
writeln('stai ploto jums prasom' ,trapecija:5:2);
writeln('ivesk rombo istrizaines');
read(t, r, O);
writeln('skanukoo?' ,O);
Readln;
readln;
end.