in reply to string manipulation
print join ":", grep { m{^/users/ctbld/} } split /:/, $ENV{INCLUDE};
However, you'll have a hard time manipulating environment variables from within a Perl program, so you'll have to do that as a one-liner
Update:
Damn it, its INCLUDE, not PATH
|
|---|