which XYZ searches the directories that are listed in the $PATH environment variable for an executable or script named XYZ and, if found, prints the path to the executable or script: $ which which /usr/bin/which
which prints nothing. which only prints the first one found. which ${progname} is equivalent to type -P ${progname}. whichpm: a cross-platform script that locates installed Perl modules by their package name. where.exe and the PowerShell command get-command.