title: Extract number not in brackets from this string using regular expressions [70-(90)]
body: <pre><code>[15-]
  [41-(32)] 
  [48-(45)] 
  [70-15] 
  [40-(64)] 
  [(128)-42] 
  [(128)-56] 
  </code></pre>
  
  <p>I have these values for which I want to extract the value not in curled brackets. If there is more than one, then add them together.</p>
  
  <p>What is the regular expression to do this?</p>
  
  <p>So the solution would look like this:</p>
  
  <pre><code>[15-] -&gt; 15
  [41-(32)] -&gt; 41
  [48-(45)] -&gt; 48
  [70-15] -&gt; 85  
  [40-(64)] -&gt; 40
  [(128)-42] -&gt; 42
  [(128)-56] -&gt; 56
  </code></pre>