$ perl -le " $_ = q{abcdef}; print for m{(.)(.)}g; a b c d e f $ perl -le " $_ = q{abcdef}; print for m{(.)(.)*}g; a f