code: def subdomain(self, domain, depth):
          
          p = self.privateparts(domain)
          if p is None or depth > len(p) - 1:
              return None
          else:
              return ".".join(p[-(depth+1):])
docs: Return so-called subdomain of specified depth in the private suffix.