title: Finding the middle number of three random numbers using only max and min functions in JAVA
body: <p>I've solved the problem, but I'm wondering if there is a faster way. </p>
  
  <p>Assuming a, b, c are randomly generated numbers, is there a way to find the middle number by only using Math.max and Math.min functions? </p>
  
  <pre><code>  med = Math.max(Math.max(Math.min(a,b),Math.min(b,c)),(Math.max(Math.min(b,c),Math.min(a,c))));
  </code></pre>
  
  <p>Thanks a lot, any response would be greatly appreciated! </p>