text: #ifndef WALLET_H
  #define WALLET_H
  
  #include <algorithm>
  #include <chrono>
  #include <ctime>
  #include <iostream>
  #include <string>
  #include <sys/time.h>
  #include <vector>
  
  using namespace std::rel_ops;
  using namespace std;
  
  using unitsB = long long;
  
  class Operation {
      unitsB money;
      tm date;
      chrono::milliseconds time;
  
  public:
      Operation(unitsB cash);
      ~Operation();
      string getDate() const;
      unitsB getUnits() const;
      chrono::milliseconds getTime();
  
  private:
      friend ostream &operator<<(ostream &, const Operation &);
      friend bool operator<(const Operation &op1, const Operation &op2);
      friend bool operator==(const Operation &op1, const Operation &op2);
  };
  
  class Wallet {
      vector<Operation> history;
      static unitsB productedMoney;
      const unitsB maxProductedMoney = 2100000000000000;
      const unitsB converter = 100000000;
      friend Wallet operator+(Wallet &&, Wallet &&);
      friend Wallet operator+(Wallet &&, Wallet &);
      friend Wallet operator+(Wallet &, Wallet &&) = delete;
      friend Wallet operator+(Wallet &, Wallet &) = delete;
      friend Wallet operator-(Wallet &&, Wallet &&);
      friend Wallet operator-(Wallet &&, Wallet &);
      friend Wallet operator-(Wallet &, Wallet &&) = delete;
      friend Wallet operator-(Wallet &, Wallet &) = delete;
      friend Wallet operator*(const Wallet &, long long n);
      friend Wallet operator*(long long n, const Wallet &);
      friend Wallet operator*(const Wallet &, int n);
      friend Wallet operator*(const Wallet &, long n);
      friend Wallet operator*(const Wallet &, unsigned long long n);
      friend Wallet operator*(const Wallet &, unsigned long n);
      friend Wallet operator*(const Wallet &, unsigned int n);
      friend Wallet operator*(unsigned int n, const Wallet &);
      friend Wallet operator*(unsigned long n, const Wallet &);
      friend Wallet operator*(unsigned long long n, const Wallet &);
      friend Wallet operator*(long n, const Wallet &);
      friend Wallet operator*(int n, const Wallet &);
      friend ostream &operator<<(ostream &, const Wallet &);
      friend bool operator<(const Wallet &w1, const Wallet &w2);
      friend bool operator==(const Wallet &w1, const Wallet &w2);
      friend bool operator!=(const Wallet &w1, const Wallet &w2);
      friend bool operator>(const Wallet &w1, const Wallet &w2);
      friend bool operator>=(const Wallet &w1, const Wallet &w2);
      friend bool operator<=(const Wallet &w1, const Wallet &w2);
  
      template <typename T, typename S> friend Wallet operator*(T, S) = delete;
  
      bool doesItExceed(unitsB units);
      void addUnitsToHistory(unitsB units);
      void addNewBToHistory(double add);
      void multiplyMoney(unitsB money, long long n);
  
  public:
      Wallet(long long n = 0);
  
      Wallet(unsigned long int n);
      Wallet(unsigned long long int n);
      Wallet(unsigned int n);
      Wallet(long int n);
      Wallet(int n);
  
      explicit Wallet(string s);
      explicit Wallet(const char *str);
  
      Wallet(Wallet &&w2);
  
      Wallet(Wallet &w2) = delete;
  
      Wallet(Wallet &&w1, Wallet &&w2);
  
      static Wallet fromBinary(const string &s);
  
      template <typename T> Wallet(T t) = delete;
  
      ~Wallet();
  
      Wallet &operator=(Wallet &&w);
  
      Wallet &operator=(Wallet &w) = delete;
  
      Wallet &operator*=(long long n);
  
      Wallet &operator*=(long n);
      Wallet &operator*=(unsigned long long n);
      Wallet &operator*=(unsigned int n);
      Wallet &operator*=(unsigned long n);
      Wallet &operator*=(int n);
  
      template <typename T> Wallet &operator*=(T x) = delete;
  
      Wallet &operator+=(Wallet &w);
  
      Wallet &operator+=(Wallet &&w);
      Wallet &operator-=(Wallet &w);
      Wallet &operator-=(Wallet &&w);
      unitsB getUnits() const;
  
      size_t opSize() const;
      const Operation operator[](int k) const;
  };
  const Wallet &Empty();
  #endif