perl -we'my @l = qw/ca qw/; for (@l) { print if /a/../c/ }'