Class Definition Example, Version 4
private int deposits; // deposits to date
private int withdrawals; // withdrawals to date
// withdraw w from account
withdrawals = withdrawals + w;
return deposits - withdrawals;
int getDeposits() { return deposits; }
int getWithdrawals() { return withdrawals; }