How to get index of the last character in a sentence
<p>I have a text file with some names and their high score next to each other:</p>

<pre><code>Sam w:10 
John S:9
Benjamin:4
</code></pre>

<p>I wondered if there was a way to get the index of last character of each because they are different lengths and I need them all for sorting.</p>