Hi I'm trying to implement a django quiz app. But can't figure out the approach i should use when trying to create a question with multiple right answers. ie, users should be able to mark multiple choices as the right answers.
This is what I've come up with so far.
class Question(models.Model): question = models.CharField(...)class Choice(models.Model):
question = models.ForeignKey(“Question”)
choice = modelsCharField(“Choice”, max_length=50)class Answer(models.Model):
question = models.ForeignKey(“Question”)
answers = models.ForeignKey(“Choice”)
Please guide me how to implement it the right way.
#python #django