0% found this document useful (0 votes)
12 views2 pages

PY2 Module 19 Quiz

Uploaded by

Naimur
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
12 views2 pages

PY2 Module 19 Quiz

Uploaded by

Naimur
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

PY2 Module 19 Quiz

1. What is Django?
A. A front-end framework for designing user interfaces.
B. A Python-based back-end web framework.
C. A database management tool.
D. A library for machine learning.

Answer: B

2. Which of the following is a feature of Django?

A. Built-in authentication system.


B. Automatic front-end creation.
C. Single-language support.
D. Non-scalable architecture.

Answer: A

3. What is the primary advantage of using Django?

A. It only supports small-scale applications.


B. It does not require any configurations.
C. It provides an admin panel out of the box.
D. It is a paid framework.

Answer: C

4. Which command is used to install Django?

A. npm install django


B. pip install django
C. apt-get install django
D. django install

Answer: B

5. What is the role of a virtual environment in Django projects?

A. To secure the application from external threats.


B. To maintain project dependencies isolated from the global environment.
C. To debug code faster.
D. To deploy the project directly to the server.

Answer: B
6. What does the django-admin startproject command do?

A. Creates a Django app inside a project.


B. Creates a new Django project directory with necessary files.
C. Installs Django on the local machine.
D. Starts the Django development server.

Answer: B

7. In Django, what does MVT stand for?

A. Model-View-Testing
B. Model-View-Template
C. Model-View-Tier
D. Model-View-Transformation

Answer: B

8. What differentiates a Django project from an app?

A. A project is a collection of apps, while an app is a single application within the project.
B. A project handles static files, while apps handle dynamic routing.
C. A project is limited to one app only.
D. An app can only exist independently and not within a project.

Answer: A

9. How do you start the Django development server?

A. django runserver
B. python manage.py runserver
C. python django-admin runserver
D. manage runserver

Answer: B

10. In Django, which file is responsible for URL mapping?

A. views.py
B. models.py
C. urls.py
D. settings.py

Answer: C

You might also like