Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.util.InputMismatchException;
- public class TestAccount {
- public static void main(String[] args) {
- //(Person p, double bal, int acctNum)
- Account act=new Account(new Person("Charlie", "Gorrill", 45), 5000.00, 12345);
- System.out.println(act.getBalance());
- act.deposit(500);
- System.out.println(act.getBalance());
- act.deposit(-500);
- System.out.println(act.getBalance());
- double amt=act.withdraw(500);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement