code: def get_type(self):
          
          for card, pattern in CARDS.items():
              if pattern.match(self.number):
                  return card
          return None
docs: Return the type if it matches one of the cards.