in reply to Re: Pipe and extract
in thread Pipe and extract

That's wrong. When you use an array on the left hand side of an assignment for backticks ("list context"), it returns a list, not a single string:

perl -le "my @list = `dir`; chomp @list; print qq([$_]) for @list"