Copy these into test classes to see if your code works.

/**
* Test the superclass BankAcct
*
**/
public class TestBankAcct
{
// test driver program // Be sure BankAcct is not abstract for this test
public static void main(String[] args) {
BankAcct x;
x = new BankAcct("A1234", 300.00);
x.deposit(50.00);
x.withdraw(20.00);
System.out.println(x.getAcctNo() + " has $" +x.getBalance());
// the balance should be A1234 has $330.00
}
}
/**
* test the checking account class
*/
public class TestCheckAcct
{
// test driver program
public static void main(String[] args) {
CheckAcct x;
x = new CheckAcct("B2234", 300.00);
x.deposit(50.00);
x.withdraw(20.00);
System.out.println(x.getAcctNo() + " has $" +x.getBalance());
// the balance should be B2234 has $329.50
}
}
/**
* test a savings account
*/
public class TestSavAcct
{
// test driver program
public static void main(String[] args) {
SavAcct x;
x = new SavAcct("C3334", 400.00, 0.05);// acct no, balance, rate
x.deposit(100.00);
x.withdraw(70.00);
x.addInt();
System.out.println(x.getAcctNo() + " has $" +x.getBalance());
// lowbal=400
// the balance should be C3334 has $400+100-70+20=$450.00
SavAcct y;
y = new SavAcct("C4131", 100.00, 0.025);
y.withdraw(50.0);
y.deposit(50.0);
y.addInt();
System.out.println(y.getAcctNo() + " has $" +y.getBalance());
//lowbal=50, bal=100, add interest 2.5%*50=$1.25
// C4143 has $101.25
//try to withdraw $150, balance goes down to 0, lowbal = 0
y.withdraw(150.00);
y.deposit(20.00);
y.addInt();
System.out.println(y.getAcctNo() + " has $" +y.getBalance());
//since lowbal went down to 0, no interest
// C4131 has $20.00
}
}