in reply to Read entire file from given folder
You're reading the $dir from STDIN? My guess is you forgot to get rid of the newline. Try
holli, /regexed monk/
And next time, please post the code that does *not* work.$dir = <STDIN>; chomp $dir;
holli, /regexed monk/
In Section
Seekers of Perl Wisdom