title: Min value array of int with streams
body: <p>I'm trying to get the min value of an array of int with streams, I'm trying to do something like:</p>
  
  <pre><code>public static int smallestInt(int[] args) {
      return Arrays.stream((Arrays.stream(args)
                  .boxed().toArray( Integer[]::new ))
                  .mapToInt(Integer::intValue).min().getAsInt;
  }
  </code></pre>
  
  <p>My question is what's the best way to do it? </p>
  
  <p>PS: There's a similar question but without sterams here
  <a href="https://stackoverflow.com/questions/1484347/finding-the-max-min-value-in-an-array-of-primitives-using-java">Finding the max/min value in an array of primitives using Java</a></p>