How can you delete running characters at the end of a string?
<p>Say I had parsed a large number like <code>130,233,320,000,000,000</code> into <code>130,233,320,,,</code> how could I recursively delete the substring of running commas to get the output like <code>130,233,320</code></p>

<p>A recursive algorithm seems easy like:</p>

<pre><code>public String parseEnd(String s) {
  if(s.substring(s.length-1) == ",") {
     return s.substring(0, s.length-2);
  }
  return s;
}
</code></pre>
