title: How to increment a string in JavaScript containing leading zeros?
body: <p>I have string like:</p>
  
  <p>MPG_0023</p>
  
  <p>I want to find something like </p>
  
  <p>MPG_0023 + 1 </p>
  
  <p>and I should get</p>
  
  <p>MPG_0024</p>
  
  <p>How to do that in JavaScript? It should take care that if there are no leading zeros, or one leading zero should still work like MPG23 should give MPG24 or MPG023 should give MPG024.</p>
  
  <p>There should be no assumption that there is underscore or leading zeros, the only thing is that first part be any string or even no string and the number part may or may not have leading zeros and it is any kind of number so it should work for 0023 ( return 0024) or for gp031 ( return gp032) etc.</p>