title: Get 3 random values from a Dictionary (with tuple string[]) without duplicates
body: <p>I have the following function:</p>
  
  <pre><code>private static string[] ReturnAnswers2(string CorrectAnswer, Dictionary&lt;string, Tuple&lt;string, string[]&gt;&gt; AnswerWrongDict, string uniqueKey)
  {
      //Get wrong answers from Item2 array and placing 1 CorrectAnswer making sure there are is no duplicated CorrectAnswer.
      string[] result = AnswerWrongDict.OrderBy(n =&gt; Guid.NewGuid())
        .Where(n =&gt; n.Value.Item2 != null &amp;&amp; !n.Value.Item2[0].Equals(CorrectAnswer) &amp;&amp; n.Value.Item1 != uniqueKey).Take(3).Select(a =&gt; a.Value.Item2[0])
        .Concat(new[] { CorrectAnswer })
        .OrderBy(n =&gt; Guid.NewGuid())
        .ToArray();
  
      return result;
  }
  </code></pre>
  
  <p>The dictionary <code>AnswerWrongDict</code> contains:</p>
  
  <ul>
  <li>First string: Some name desc (no duplicates, Ignored here)</li>
  <li>Second string in tuple: uniqueKey (no
  duplicates) </li>
  <li>Third string[]: array of wrong answers (can be different sizes
  or even null)</li>
  </ul>
  
  <p>What it does it gets 4 answers: 3 random wrong answers and 1 correct.
  The wrong answers are inside a string[] in a tuple dictionary.</p>
  
  <p>This works, only issue that i can receive duplicate wrong answers from the third value string[] (a.Value.Item2[0]).</p>
  
  <p>How do i make sure there are no duplicates from the 3 wrong answers?</p>
  
  <p>If I place <code>Distinct()</code> after <code>.OrderBy(n =&gt; Guid.NewGuid())</code> it will remove duplicates but i can get sometimes 3 answers while I need 4 (because duplicated distincted).</p>
  
  <p>Can't seem to solve this. Help appreciated. </p>