code: def _getdefaultlocale(
      envvars=("LC_ALL", "LC_CTYPE", "LANG", "LANGUAGE")
  ):
      try:
          # check if it's supported by the _locale module
          import _locale
  
          code, encoding = _locale._getdefaultlocale()
      except (ImportError, AttributeError):
          pass
      else:
          # make sure the code/encoding values are valid
          if sys.platform == "win32" and code and code[:2] == "0x":
              # map windows language identifier to language name
              code = windows_locale.get(int(code, 0))
          # ...add other platform-specific processing here, if
          # necessary...
          return code, encoding
  
      # fall back on POSIX behaviour
      import os
  
      lookup = os.environ.get
      for variable in envvars:
          localename = lookup(variable, None)
          if localename:
              if variable == "LANGUAGE":
                  localename = localename.split(":")[0]
              break
      else:
          localename = "C"
      return _parse_localename(localename)
  
imports: import sys
  import encodings
  import encodings.aliases
  import re
  import _collections_abc
  from builtins import str
  import functools
label_desc: Use image node_id 23 for calling a global function with example usage: _getdefaultlocale(envvars) and returns: _parse_localename, code,  encoding