code: def head(task):
      """Return the top level node of a task"""
  
      if istask(task):
          return task[0]
      elif isinstance(task, list):
          return list
      else:
          return task
  
imports: from __future__ import annotations
  from collections import deque
  from dask.core import istask, subs
label_desc: Use image node_id 1 for calling a global function with example usage: head(task) and returns: task, list, task