code: def main(args):
      import sys
  
      def print_symbols(table, level=0):
          indent = "    " * level
          nested = "nested " if table.is_nested() else ""
          if table.get_type() == "module":
              what = f"from file {table._filename!r}"
          else:
              what = f"{table.get_name()!r}"
          print(
              f"{indent}symbol table for {nested}{table.get_type()} {what}:"
          )
          for ident in table.get_identifiers():
              symbol = table.lookup(ident)
              flags = ", ".join(symbol._flags_str()).lower()
              print(
                  f"    {indent}{symbol._scope_str().lower()} symbol {symbol.get_name()!r}: {flags}"
              )
          print()
  
          for table2 in table.get_children():
              print_symbols(table2, level + 1)
  
      for filename in args or ["-"]:
          if filename == "-":
              src = sys.stdin.read()
              filename = "<stdin>"
          else:
              with open(filename, "rb") as f:
                  src = f.read()
          mod = symtable(src, filename, "exec")
          print_symbols(mod)
  
imports: import _symtable
  from _symtable import USE, DEF_GLOBAL, DEF_NONLOCAL, DEF_LOCAL, DEF_PARAM, DEF_IMPORT, DEF_BOUND, DEF_ANNOT, SCOPE_OFF, SCOPE_MASK, FREE, LOCAL, GLOBAL_IMPLICIT, GLOBAL_EXPLICIT, CELL
  import weakref
label_desc: Use image node_id 2 for calling a global function with example usage: main(args) without return types