in reply to Perl one-liner Quotes help

In the second and third examples, you forgot a final '

If you want ' print working try

perl -e "print 'hello \'\'  ' "

or

perl -e "print \"hello \'\'  \" "

(Like the first example but with \')

The second and third, wait for something because they (with -lane) mean

BEGIN { $/ = "\n"; $\ = "\n"; } LINE: while (defined($_ = <ARGV>)) { chomp $_; our(@F) = split(' ', $_, 0); print 'hello '; }

Update: Just inverted order of things and corrected some errors.

Alex's Log - http://alexlog.co.cc