title: Copy List elements N times using Stream API
body: <p>Is there a way to copy some List (or combined string if necessary) N times in Java using Stream API</p>
  
  <p>If the list consists of <code>{"Hello", "world"}</code> and N = 3, the result should be <code>{"Hello", "world", "Hello", "world", "Hello", "world"}</code></p>
  
  <p>What I've done so far is to get combined String element and I am not sure how to procees to copy it N times. While I can do it externally, I would like to see if it is possible to do with the help of streams</p>
  
  <pre><code>Optional&lt;String&gt; sentence = text.stream().reduce((value, combinedValue) -&gt; { return value + ", " + combinedValue ;});
  </code></pre>
  
  <p>I would like to use stream, because I am planning to continue with other stream operations after the one above</p>