Java Reference
In-Depth Information
2 quarters
1 dimes
0 nickles
3 pennies
PP 2.12 Write an application that prompts for and reads an integer rep-
resenting the length of a square's side, then prints the square's
perimeter and area.
PP 2.13 Write an application that prompts for and reads the numerator
and denominator of a fraction as integers, then prints the deci-
mal equivalent of the fraction.
PP 2.14 Create a revised version of the Snowman applet with the following
modifications:
Add two red buttons to the upper torso.
Make the snowman frown instead of smile.
Move the sun to the upper-right corner of the picture.
Display your name in the upper-left corner of the picture.
Shift the entire snowman 20 pixels to the right.
PP 2.15 Write an applet that writes your name using the drawString
method. Embed a link to your applet in an HTML document
and view it using a Web browser.
PP 2.16 Write an applet that draws the Big Dipper. Add some extra stars
in the night sky.
PP 2.17 Write an applet that draws some balloons tied to strings. Make
the balloons various colors.
PP 2.18 Write an applet that draws the Olympic logo. The circles in the
logo should be colored, from left to right, blue, yellow, black,
green, and red.
PP 2.19 Write an applet that draws a house with a door (and doorknob),
windows, and a chimney. Add some smoke coming out of the
chimney and some clouds in the sky.
PP 2.20 Write an applet that displays a business card of your own design.
Include both graphics and text.
PP 2.21 Write an applet that displays your name in shadow text by draw-
ing your name in black, then drawing it again slightly offset in a
lighter color.
PP 2.22 Write an applet that shows a pie chart with eight equal slices, all
colored differently.
 
Search WWH ::




Custom Search