code: def _isbtaddr(address):
      
      # Define validity regex. Accept either ":" or "-" as separators.
      global _validbtaddr
      if _validbtaddr is None:
          import re
          _validbtaddr = re.compile("((\d|[a-f]){2}(:|-)){5}(\d|[a-f]){2}",
                  re.IGNORECASE)
      import types
      if not isinstance(address, str):
          return False
      return _validbtaddr.match(address) is not None
docs: Returns whether the given address is a valid bluetooth address.
      For example, "00:0e:6d:7b:a2:0a" is a valid address.
  
      Returns False if the argument is None or is not a string.