code: def isiterable(obj, reject_string=True):
      
  
      iterable =  hasattr(obj, '__len__')
  
      if reject_string:
          iterable = iterable and not isinstance(obj, str)
  
      return iterable
docs: convenience tool to detect if something is iterable.
      in python3, strings count as iterables to we have the option to exclude them
  
      Parameters:
      -----------
      obj : object to analyse
      reject_string : bool, whether to ignore strings
  
      Returns:
      --------
      bool, if the object is itereable.