code: def print_tokens(tokens, style=None, true_color=False, file=None):
      
      if style is None:
          style = DEFAULT_STYLE
      assert isinstance(style, Style)
  
      output = create_output(true_color=true_color, stdout=file)
      renderer_print_tokens(output, tokens, style)
docs: Print a list of (Token, text) tuples in the given style to the output.
      E.g.::
  
          style = style_from_dict({
              Token.Hello: '#ff0066',
              Token.World: '#884444 italic',
          })
          tokens = [
              (Token.Hello, 'Hello'),
              (Token.World, 'World'),
          ]
          print_tokens(tokens, style=style)
  
      :param tokens: List of ``(Token, text)`` tuples.
      :param style: :class:`.Style` instance for the color scheme.
      :param true_color: When True, use 24bit colors instead of 256 colors.
      :param file: The output file. This can be `sys.stdout` or `sys.stderr`.