cc [flag . . . ] file . . . -lgen [library] . . .
char pathfind (const char path, const char name, const char mode);
|u||set user ID bit|
|g||set group ID bit|
Options read, write, and execute are checked relative to the real (not the effective) user ID and group ID of the current process.
If the file name, with all the characteristics specified by mode, is found in any of the directories specified by path, then pathfind returns a pointer to a string containing the member of path, followed by a slash character (/), followed by name.
If name begins with a slash, it is treated as an absolute path name, and path is ignored.
An empty path member is treated as the current directory. ./ is not prepended at the occurrence of the first match; rather, the unadorned name is returned.
pathfind (getenv ("PATH"), "ls", "rx")