my $string = "Tonight too many to's were used to explain."; my (@matches) = $string =~ /\b(to)\b/g; print($_,"\n") foreach @matches;