def lazify_task(task, start=True):
 if (not istask(task)):
  return task
 (head, tail) = (task[0], task[1:])
 if ((not start) and (head in (list, reify))):
  task = task[1]
  return lazify_task(start=False, *tail)
 else:
  return ((head,) + tuple([lazify_task(arg, False) for arg in tail]))

def lazify_task ( task , start = True ) : if ( not istask ( task ) ) : return task ( head , tail ) = ( task [ 0 ] , task [ 1 : ] ) if ( ( not start ) and ( head in ( list , reify ) ) ) : task = task [ 1 ] return lazify_task ( start = False , * tail ) else : return ( ( head , ) + tuple ( [ lazify_task ( arg , False ) for arg in tail ] ) )
given a task .