def detect_range(line=None):
 if ('[' in line):
  return True
 else:
  return False

def detect_range ( line = None ) : if ( '[' in line ) : return True else : return False
a helper function that checks a given host line to see if it contains a range pattern described in the docstring above .