// Written by: Darren Gates & Ray Klefstad // Date: January 2000 // School: U.C. Irvine import java.awt.*; import java.applet.*; public class GraphicsExample extends Applet { public void init() { } public void paint(Graphics g) { // draw the face g.drawOval(70,70,150,150); g.drawOval(120,120,15,15); g.drawOval(155,120,15,15); g.drawArc(115,150,60,30,190,170); // draw the hat g.drawRect(120,20,50,50); g.drawLine(90,70,195,70); // draw the beard int [] x = {130,145,160}; int [] y = {220,250,220}; int n = 3; g.drawPolygon(x, y, n); } }