CS U540 Sample Problems


      (Scalable Drawing) Write a function that takes integer arguments x, y, width, and height and draws the picture shown below. The sky is blue; the cloud is white; the house is red; the window and door are black.

The picture is shown in different positions with different heights. It is also shown twice with a super-imposed grid so that you can tell where the cloud, house, door, and window are within the drawing. Your function should not draw the grid.


Last Updated: May 27, 6:07.m. by
Harriet Fell
College of Computer Science, Northeastern University
360 Huntington Avenue #WHV-340,
Boston, MA 02115
Internet: fell@ccs.neu.edu
Phone: (617) 373-2198 / Fax: (617) 373-5121
The URL for this document is: http://www.ccs.neu.edu/home/fell/CSU540/exams/ScalableDrawingProblem.html