Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package com.company;
- import java.io.IOException;
- import java.util.Scanner;
- public class Account extends json {
- Scanner myScan = new Scanner(System.in);
- private double balance;
- private double newBalance;
- private double addBalance;
- public Account() {
- }
- public double getBalance() {
- balance = getBalanceJson();
- getBalanceJson();
- return balance;
- }
- public double setBalance() throws IOException {
- System.out.printf("Please Enter the Deposit Amount: ");
- addBalance = Double.parseDouble(myScan.nextLine());
- newBalance = balance + addBalance;
- return newBalance;
- }
- }
Add Comment
Please, Sign In to add comment