
Django Quiz 2 kurs(1)
Authored by Біржан Айқын
Computers
12th Grade
Used 39+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
20 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the str method in a Django model accomplish?
Validates user input
Retrieves data from the database
Converts data types
None of the above
It lets you specify how an instance of the model will be represented as a string
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the purpose of the models.py file?
To define the shape of the data objects to be stored in a database
Contains the HTML templates for the project
Handles user authentication
Manages URL routing
Implements business logic
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What file contains the list of INSTALLED_APPS in a Django project?
settings.py
urls.py
models.py
views.py
admin.py
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the Django command to create a user/password for the admin user interface?
createsuperuser
addadminuser
createsuperadmin
addsuperuser
makeadmin
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What file in a Django application do you edit to make sure a model appears in the admin interface?
models.py
admin.py
settings.py
views.py
urls.py
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the "sqlmigrate" option accomplish in a Django application?
Executes a SQL injection attack
Deletes the database
Reverses a database migration
It lets you see the SQL that will run to effect a migration
None of the above
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the default database backend for Django projects when they are first set up?
sqlite3
MySQL
PostgreSQL
MongoDB
MariaDB
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?