COM 1100 Professor Fell Quiz 1A September 25, 1997
Name

1. Use the windows below to show the output of the following code:
(The grid boxes are 20 pixels apart.)

// function prototype
void somestuff();

main()
{
BigSquarePair();       // Makes the windows
somestuff();
cout << "This quiz is easy." << endl;

PaintRect(20, 30, 50, 240);
PaintOval(140, 100, 320, 200);
DrawLine(100, 40, 140, 300);
FrameCircle(80, 100, 20);

PressReturn("Done!");
}

void somestuff()
{
int x;
int y;
x = 3;
y = 19;
cout << "x = " << x << endl << "y = " << y << endl;
cout << "x + y = " << x + y << " and y/x = " << y/x << endl;
cout << "y - x * 3 - 10 = " << y - x * 3 - 10 << endl;
}

2. What is the difference between the files warmup.mu and warmup.cp? Why do we need both? (The Greek letter "mu" is not yet available in HTML.)

Last Updated: September 28, 1997 10:34 am by

Harriet Fell
College of Computer Science, Northeastern University
360 Huntington Avenue #161CN,
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/COM1100/QUIZ/QUIZ1A.html