Lab Assignment 8
CS202, Summer 2006

Please upload your source code files using CSNS. Note that file uploading will be disabled automatically after the lab ends, so please turn in your work on time.

1.(10pt)  [Lab Manual (Chapter 11)] p25. Events.

2.(10pt) Write a Java application to draw a Ying-Yang symbol as shown below:

[Yingyang.jpg]

Note that if the display window is resized, your Ying-Yang symbol must scale accordingly.

3. (15pt)  [Simple Calculator, Part III] Add event handling such that arithmetic operations work properly. You may leave decimal point, sign, backspace, and all the functions out for now. Note that since we are working on a "simple" calculator (as oppose to a "scientific" one), we will consider the operators all have the same precedence. For example, 1+2*3 will yield 9 instead of 7. A simplified version of the program is available here for your reference.