code: def get_typename(x):
      '''Returns the name of the type of x, if x is an object.  Otherwise, returns the name of x.
      '''
      if isinstance(x, type):
          ret = x.__name__
      else:
          ret = x.__class__.__name__
      return ref get_typename(x):
      '''Returns the name of the type of x, if x is an object.  Otherwise, returns the name of x.
      '''
      if isinstance(x, type):
          ret = x.__name__
      else:
          ret = x.__class__.__name__
      return ret
docs: Returns the name of the type of x, if x is an object.  Otherwise, returns the name of x.