Add Initial commit for insert and constraints

This commit is contained in:
Lev
2021-06-12 19:04:03 -05:00
parent bcf1ad6fa4
commit 8eedc8a51e
13 changed files with 4271 additions and 0 deletions

View File

@ -0,0 +1,21 @@
#pragma once
#include <string>
#include <map>
class Wallet
{
public:
Wallet();
/** insert currency to the wallet */
void insertCurrency(std::string type, double amount);
/** check if the wallet contains at least this much currency */
bool containsCurrency(std::string type, double amount);
/** generate a string representation of the wallet */
std::string toString();
private:
std::map<std::string, double> currencies;
};