title: How do I get the last value in a string separated by commas?
body: <p>I have this string </p>
  
  <pre><code>let data = 123,456,7,8,9,10
  </code></pre>
  
  <p>I want to extract the last value separated by a "," which in this case would  be 10, and its not necessarily a two digit value.</p>
  
  <p>I tried this:</p>
  
  <pre><code>var data = 123,456,7,8,9,10
  data = data.last!
  </code></pre>