Advertisement
Guest User

Untitled

a guest
Apr 27th, 2015
215
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.61 KB | None | 0 0
  1. import java.util.Scanner;
  2. public class Account {
  3. public static void main(String[] args) { // TODO Auto-generated method stub
  4. Scanner input= new Scanner (System.in);
  5.  
  6. int id;
  7. double balance;
  8. double annualInterestRate;
  9.  
  10.  
  11. public double getbalance() {
  12. return balance;
  13. }
  14.  
  15. public double getAnnualInterestRate() {
  16. return annualInterestRate;
  17. }
  18.  
  19. public double getMonthlyInterestRate() {
  20. return annualInterestRate / 12;
  21. }
  22.  
  23. public void withdraw(double amount) {
  24. balance -= amount;
  25. }
  26.  
  27. public void deposit(double amount) {
  28. balance += amount;
  29. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement