use warnings; use strict; my $data = do { local $/; }; my @strings = $data =~ /\"([^\"]*)\"/g; print map{"<$_>\n"}@strings; =Prints <> <> =cut __DATA__ nothing "hello" foo "bar" quz "hello" "world" foo "bar" quz "baz" blah "" blah "" blah nothing "example 1 for instance"