How to split string by repeated characters? : <p>I'm doing a codewars kate where I need to implement code highlighting. I need to split the string of code into strings of repeated characters, add proper highlighting tags to them and finally connect it all and return. You can train this kata on your own (<a href="https://www.codewars.com/kata/roboscript-number-1-implement-syntax-highlighting" rel="nofollow noreferrer">https://www.codewars.com/kata/roboscript-number-1-implement-syntax-highlighting</a>). The first step I thought of is to split the code by repeated characters. But i found it hard to come up with working algorithm. So, I need your help.</p>

<p>Input: <code>"FFFR345F2LL"</code></p>

<p>Output: <code>"FFF", "R", "345", "F", "2", "LL"</code></p>
