code: def display(text, mode='exec', file=None):
      
  
      if file is None:
          file = sys.stdout
  
      ast_section = StringIO()
      a(text, mode=mode, file=ast_section)
  
      code_section = StringIO()
      d(text, mode=mode, file=code_section)
  
      rendered = _DISPLAY_TEMPLATE.format(
          text=text,
          ast=ast_section.getvalue(),
          code=code_section.getvalue(),
      )
      print(rendered, file=file)
docs: Show `text`, rendered as AST and as Bytecode.
  
      Parameters
      ----------
      text : str
          Text of Python code to render.
      mode : {'exec', 'eval'}, optional
          Mode for `ast.parse` and `compile`.  Default is 'exec'.
      file : None or file-like object, optional
          File to use to print output.  If the default of `None` is passed, we
          use sys.stdout.