title: Subtracting lowest number from several numbers
body: <p>I have two numbers. I want the lower number to be the subtracted from both values.</p>
  
  <pre><code>x: 1000
  y: 200
  =&gt; result: x = 800 and y = 0.
  </code></pre>
  
  <p>The following is kinda ugly to me, so is there a better approach I could do this?</p>
  
  <pre><code>if (x &lt;= y) {
      y = y - x;
      x = 0
  } else {
      x = x - y;
      y = 0;
  }
  </code></pre>