title: Display only one instance of same object in model (Distinct other instances of same object)
body: <p>I am building a simple question and answer site and I am trying to implement a functionality in which user can <code>upload 4 answers But I am trying to hide show only any one answer</code> And this is showing all the answers related to a question.</p>
  <p><strong>For Example :-</strong> question_a has 4 answers then i am trying to show any one of them.</p>
  <p>models.py</p>
  <pre><code>class Question(models.Model):
      user = models.ForeignKey(User, on_delete=models.CASCADE)
      title = models.CharField(max_length=30)
      marked = models.BooleanField(booleanField)
  
  class Answer(models.Model):
      user = models.ForeignKey(User, on_delete=models.CASCADE)
      question_of = models.ForeignKey(BlogPost, on_delete=models.CASCADE)
      body = models.CharField(max_length=30)
  </code></pre>
  <p>views.py</p>
  <pre><code>def page(request):
      query_2 = Answer.objects.filter(question_of__marked=True)[:1]
  
      context = {'query_2':query_2}
      return render(request, 'page.html', context)
  </code></pre>
  <p>In this query I am trying to show Answers of qustions which have <code>marked=True</code> and i am also trying to show only one answer of a question But it is showing 4.</p>
  <p>And after using [:1] it is only showing result in all.</p>
  <ul>
  <li>I also tried <code>.distinct()</code> but it made no effect on results.</li>
  </ul>
  <p><strong>What i am trying to do ?</strong></p>
  <p>I am trying to show first answer of every question that has <code>marked=True</code></p>
  <p>I will really appreciate your Help. Thank You</p>