which
which is a Linux command in the Search & Find category, rated intermediate difficulty. Shows the full path of a command executable. The syntax is which [options] command. Key options and parameters: command — command name to locate. It returns full path to executable. A practical example: which python3 which ls # Output: /usr/bin/ls which -a python3 # Show all matching paths A close relative is find, which searches for files and directories in a directory hierarchy. A close relative is locate, which finds files by name using a prebuilt database. Faster than find. A close relative is updatedb, which updates the database used by locate. Run as root periodically. More about this category: Linux search commands — find, locate, which, whereis, and more. Find files and commands on the system. Related Search & Find commands: find, locate, updatedb, whereis, type, grep -r, ack, rg.