PROCEDURE lampa;

VAR
	a,b,c,d,e,f,g,h,i,m,numberofrect: INTEGER;

BEGIN
a:=9;
b:=21;
c:=5;
d:=2;
e:=4;
f:=2;
g:=1;
h:=1;
i:=1;

PenFore(65000,6500,6500);

poly(0,0,0,b);
poly(0,0,a,0);
poly(a,0,a,b);
poly(a,b,0,b);
poly(a,0,a+c,0);
poly(a,b,a+c,b);
poly(a+c,0,a+c,b);
poly(a,b,a,b+c);
poly(a,b+c,0,b+c);
poly(0,b+c,0,b);
poly(0,0,0,-c);
poly(0,-c,a,-c);
poly(a,-c,a,0);
poly(0,0,-c,0);
poly(-c,0,-c,b);
poly(-c,b,0,b);
poly(-c,0,-c-d,0);
poly(-c,b,-c-d,b);
poly(-c-d,b,-c-d,b-e);
poly(-c-d,b-e,-c-d+g,b-e);
poly(-c-d+g,b-e,-c-d+g,b-e-f);
poly(-c-d,b-e-f,-c-d+g,b-e-f);
poly(-c-d,0,-c-d,e);
poly(-c-d,e,-c-d+g,e);
poly(-c-d+g,e,-c-d+g,e+f);
poly(-c-d+g,e+f,-c-d,e+f);
poly(-c-d,e+f,-c-d,b-e-f);
poly(a+c,0,a+c+d,0);
poly(a+c+d,0,a+c+d,e);
poly(a+c+d,e,a+c+d-g,e);
poly(a+c+d-g,e,a+c+d-g,e+f);
poly(a+c+d-g,e+f,a+c+d,e+f);
poly(a+c,b,a+c+d,b);
poly(a+c+d,b,a+c+d,b-e);
poly(a+c+d,b-e,a+c+d-g,b-e);
poly( a+c+d-g,b-e,a+c+d-g,b-e-f);
poly( a+c+d-g,b-e-f,a+c+d,b-e-f);
poly(a+c+d,b-e-f,a+c+d,e+f);
poly(0,0,-h,-i);
poly(-h,-i,0-h,-c+i);
poly(0,-c,0-h,-c+i);
poly(0,b,-h,b+i);
poly(-h,b+i,0-h,b+c-i);
poly(0,b+c,0-h,b+c-i);
poly(a,0,a+h,-i);
poly(a+h,-i,a+h,-c+i);
poly(a,-c,a+h,-c+i);
poly(a,b,a+h,b+i);
poly(a+h,b+i,a+h,b+c-i);
poly(a,b+c,a+h,b+c-i);
poly(-c,0,-c-i,-h);
poly(-c-i,-h,-c-d+i,-h);
poly(-c-d+i,-h,-c-d,0);
poly(a+c,0,a+c+i,-h);
poly(a+c+i,-h,a+c+d-i,-h);
poly(a+c+d-i,-h,a+c+d,0);
poly(-c,b,-c-i,b+h);
poly(-c-i,b+h,-c-d+i,b+h);
poly(-c-d+i,b+h,-c-d,b);
poly(a+c,b,a+c+i,b+h);
poly(a+c+i,b+h,a+c+d-i,b+h);
poly(a+c+d-i,b+h,a+c+d,b);

numberofrect:=100;

for m:=0 to numberofrect do begin
rect(1+random*(a-2),1+random*(b-2),1+random*(a-2),1+random*(b-2));
END;

numberofrect:=50;

for m:=0 to numberofrect do begin
rect(-1-random*(c-2),1+random*(b-2),-1-random*(c-2),1+random*(b-2));
end;

numberofrect:=50;

for m:=0 to numberofrect do begin
rect(a+1+random*(c-2),1+random*(b-2),1+a+random*(c-2),1+random*(b-2));
END; END; 

Run(lampa);