Advertisement
Guest User

Untitled

a guest
Jul 25th, 2017
94
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.52 KB | None | 0 0
  1. #include <iostream>
  2. class Patente {
  3. private:
  4.     std::string patente;
  5. public:
  6.     Patente(const std::string p="AAA000");
  7.     Patente(const Patente& p);
  8.    
  9.     bool operator<(const Patente& p) const;
  10.     bool operator>(const Patente& p) const;
  11.     bool operator==(const Patente& p) const;
  12.     operator int();
  13.     friend std::ostream& operator<<(std::ostream& os, const Patente& p);
  14. };
  15.  
  16. bool Patente::operator>(const Patente& p) const {
  17.     if (this->patente>p.patente)
  18.         return true;
  19.     return false;
  20. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement