chmod 775 isn't quite making everything readable
and writeable. It makes all files and directories readable
and executable for everyone, and writeable for the owner
and anyone who is in the same group as the group owing a
file.
Anyway, I wouldn't use a Perl solution for this problem -
I'd use the -R option of chmod.
Abigail