next up previous contents index
Next: Draw a whole rectangle Up: Program examples Previous: Program examples   Contents   Index

Draw houses

Figure: Houses
\includegraphics[width=15 cm, clip]{pics/maisons.eps}

to house :c
repeat 4[fd 20*:c rt 90]
fd 20*:c rt 30
repeat 3[fd 20*:c rt 120]
end

to place :c
pu lt 30 bk :c*20 rt 90 fd :c*22 lt 90 pd
end

to hut
cs pu lt 90 fd 200 rt 90 pd ht 
house 3 place 3 house 5 place 5 house 7 place 7 house 10
end



Loïc 2008-06-08