title: Convert a list of long to a iterable of integers using Java 8
body: <p>How could I convert a list of long to a list of integers. I wrote :</p>
  
  <pre><code>longList.stream().map(Long::valueOf).collect(Collectors.toList())
  //longList is a list of long.
  </code></pre>
  
  <p>I have an error : </p>
  
  <pre><code>Incompatible types. Required iterable&lt;integer&gt; but collect was inferred to R.
  </code></pre>
  
  <p>May anyone tell me how to fix this?</p>