locating

Type

type shows what kind of thing you're running, be it an alias, function, or binary program.

1type cd
2type ls
3type -P ls
4type -a cat

Whereis the Program

Where is grep and all its configuration files?

1whereis grep

Which one of these is the binary file which you actually use?

1which grep