from django.db import models class Question(models.Model): question_text = models.CharField(max_length=200) pub_date = models.DateTimeField('date published') def __str__(self): return self.question_textThis code defines a Question model that has a question_text field of maximum length 200 characters and a pub_date field of type DateTimeField with the help of the Django ORM. The __str__ method lists the question text attribute when the object is printed. This example uses the Django library, specifically the models package, to define a database model for questions in the polls app. The package provides an easy-to-use ORM that abstracts away much of the SQL needed to interact with the database.