tmp.c/account.cpp
Vincent Batts 768916ff0d
*.cpp *.h: vim settings for 2-spaces instead of tabs
Signed-off-by: Vincent Batts <vbatts@hashbangbash.com>
2025-02-10 13:59:55 -05:00

24 lines
403 B
C++

#include <iostream>
#include "account.h"
Account::Account ( double initial_balance ) : balance(initial_balance) {
}
Account::~Account () {
std::cout << "account deleted" << std::endl;
}
double Account::getBalance() const {
return balance;
}
void Account::deposit(double amount) {
balance += amount;
}
void Account::withdraw(double amount) {
balance -= amount;
}
// vim:set sts=2 sw=2 et: