/**                                                        // line 1
 * Simple representation of a bank account                 // line 2
 *                                                         // line 3
 * @author Hyrum D. Carroll                                // line 4
 * @version 0.2 (August 27, 2020)                          // line 5
 */                                                        // line 6
public class SimpleBankAccount{                            // line 7

    private double balance;                                // line 9

    /**                                                    // line 11
     * Constructor for objects of class SimpleBankAccount  // line 12
     */                                                    // line 13
    public SimpleBankAccount(){                            // line 14
        balance = 0.0;                                     // line 15
    }                                                      // line 16

    /**                                                    // line 18
     * Add money to the balance                            // line 19
     *                                                     // line 20
     * @param  amount the amount to deposit                // line 21
     * @return void                                        // line 22
     */                                                    // line 23
    public void deposit(double amount){                    // line 24
        balance = balance + amount;                        // line 25
    }                                                      // line 26

    /**                                                    // line 28
     * Remove money from the balance                       // line 29
     *                                                     // line 30
     * @param  amount the amount to withdraw               // line 31
     * @return true (success) or false (failure)           // line 32
     */                                                    // line 33
    public boolean withdraw(double amount){                // line 34
        if( balance - amount >= 0 ){                       // line 35
            balance -= amount;                             // line 36
            return true;                                   // line 37
        }else{                                             // line 38
            return false;                                  // line 39
        }                                                  // line 40
    }                                                      // line 41

    /**                                                    // line 43
     * Get the balance                                     // line 44
     *                                                     // line 45
     * @return the balance                                 // line 46
     */                                                    // line 47
    public double getBalance(){                            // line 48
         return balance;                                   // line 49
    }                                                      // line 50
}                                                          // line 51