I suppose `executable-find` function is better than `which` command.
`executable-find` works on Windows platform. And some `which`
command(`zsh` builtin which etc) shows error message if the command is
not found. This code does not work with such `which` command.

See also
http://www.gnu.org/software/emacs/manual/html_node/elisp/Locating-Files.html