in reply to STDIN help for a new Perl coder

You forgot to remove the trailing newline
chomp( my $dir = <STDIN> );

Replies are listed 'Best First'.
Re^2: STDIN help for a new Perl coder
by perlJourney (Initiate) on Jul 15, 2009 at 18:02 UTC
    Thank you I was not aware of the trailing new line following it... I will read up on chomp.