Feb-22-2018, 01:22 PM
(This post was last modified: Feb-22-2018, 01:22 PM by Gribouillis.)
Your code has already been written (thanks stackoverflow:). Look at this
>>> from distutils.spawn import find_executable >>> find_executable('python3') '/usr/bin/python3'In python 3, there is also
shutil.which()