title: Generate random pairs of from list of integer without duplication of the number
body: <p>I have to list of integer like {1,3,4,5,6,7}
  I would like to generate an array, which contains pairs from the a and b arrays, in a random order, without duplicates. For example I would like to get the following result:</p>
  <p>c={(1,5),(3,7),(4,6),...}</p>
  <p>and if we found odd numbers, then it should give us any random selection for that last number</p>
  <p>{1,3,4,5,6,7,8}</p>
  <p>c={(1,5),(3,7),(4,6,8),...}</p>
  <p>I have used below code to achieve this, but it's not working as expected.</p>
  <pre><code>int[] a={1,2,3,4,5};
      int[] b={6,7};
      List&lt;int[]&gt; list = new ArrayList&lt;&gt;();
      for (int i = 0; i &lt; a.length; ++i)
          for (int j = 0; j &lt; b.length; ++j)
              list.add(new int[] {a[i], b[j]});
      Collections.shuffle(list);
  </code></pre>
  <p>Thanks!</p>