http://www.perlmonks.org?node_id=512779


in reply to Elegant way to split into sequences of identical chars?

You may want to take a look at the node: Puzzlement in Splitsville which discusses this exact issue. Lots of answers there.