FileDocCategorySizeDatePackage
Q3.javaAPI DocExample691Fri Nov 02 15:26:08 GMT 2001None

Q3

public class Q3 extends Applet

Fields Summary
int
counter
double
totalMoney
double
myMoney
double
yourMoney
double
theirMoney
double
ourMoney
int
averageMoney
Constructors Summary
Methods Summary
public voidpaint(java.awt.Graphics g)

		counter=0;
	    totalMoney=myMoney+yourMoney+theirMoney+ourMoney;
		mayMoney == 55.99;
		yourMoney = 22.55;
		theirMoney = 666.88;
		ourMoney = 6543.34;
		
		averageMoney=(int)totalMoney/counter;
		g.drawString("total money = " + totalMoney, 20, 50);
		g.drawString("average money = " + averageMoney, 20, 50);