$_ = 'aaa%bbbbb%cccccc%ddd'; print $-[0], ' ' while /%/g; print $/'