human
Complete this python program:
def get_sublime_exe():
assistant
#Here is the Python code you requested.

    """Utility function to get the full path to the currently executing
    Sublime instance.
    """
    processes = ['subl', 'sublime_text']
    def check_processes(st2_dir=None):
        if ((st2_dir is None) or os.path.exists(st2_dir)):
            for process in processes:
                try:
                    if (st2_dir is not None):
                        process = os.path.join(st2_dir, process)
                    m = SUBLIME_VERSION.search(check_output([process, '-v'], use_texpath=False))
                    if (m and (m.group(1) == version)):
                        return process
                except:
                    pass
        return None
    platform = sublime.platform()
    plat_settings = get_setting(platform, {})
    sublime_executable = plat_settings.get('sublime_executable', None)
    if sublime_executable:
        return sublime_executable
    if hasattr(get_sublime_exe, 'result'):
        return get_sublime_exe.result
    if hasattr(sublime, 'executable_path'):
        get_sublime_exe.result = sublime.executable_path()
        if (platform == 'osx'):
            get_sublime_exe.result = os.path.normpath(os.path.join(os.path.dirname(get_sublime_exe.result), '..', 'SharedSupport', 'bin', 'subl'))
        elif ((platform == 'linux') and (not get_sublime_exe.result.endswith('subl'))):
            subl = which('subl')
            if (subl is not None):
                try:
                    m = SUBLIME_VERSION.search(check_output([subl, '-v'], use_texpath=False))
                    if (m and (m.group(1) == sublime.version())):
                        get_sublime_exe.result = subl
                except:
                    pass
        return get_sublime_exe.result
    elif ((platform == 'windows') and (sys.executable != 'python') and os.path.isabs(sys.executable)):
        get_sublime_exe.result = sys.executable
        return get_sublime_exe.result
    version = sublime.version()
    result = check_processes()
    if (result is not None):
        get_sublime_exe.result = result
        return result
    if (platform == 'windows'):
        st2_dir =...