code: def show_summary(successes, failures, *, reporter=None):
      """Shows a summary detailing which examples were successful and which failed."""
      if reporter:
          reporter.write("-" * reporter.terminal_width)
          if failures:
              reporter.write("FAILED:\n", "Red")
              for example in failures:
                  reporter.write("  %s\n" % example)
          else:
              reporter.write("ALL EXAMPLES PASSED\n", "Green")
      else:
          if successes:
              print("SUCCESSFUL: ", file=sys.stderr)
              for example in successes:
                  print("  -", example, file=sys.stderr)
          else:
              print("NO SUCCESSFUL EXAMPLES", file=sys.stderr)
  
          if failures:
              print("FAILED: ", file=sys.stderr)
              for example in failures:
                  print("  -", example, file=sys.stderr)
          else:
              print("NO FAILED EXAMPLES", file=sys.stderr)
  
file_path: sympy/examples/all.py
imports: import optparse
  import os
  import sys
  import traceback
  import sympy
label_desc: Use image node_id 5 for calling a global function with example usage: show_summary(successes, failures) without return types