Complete the code to import the function needed to define URL patterns.
from django.urls import [1]
The path function is used to define URL patterns in Django's urlpatterns list.
Complete the code to define a simple URL pattern that maps the root URL to a view named 'home_view'.
urlpatterns = [
[1]('', home_view, name='home'),
]The path function is used to define URL patterns, mapping the empty string '' (root URL) to the home_view function.
Fix the error in the URL pattern by completing the code to correctly include another URLconf module named 'blog.urls'.
urlpatterns = [
path('blog/', [1]('blog.urls')),
]The include function is used to include other URL configurations inside the main urlpatterns list.
Fill both blanks to create a URL pattern that maps 'about/' to a view called 'about_view' with the name 'about'.
urlpatterns = [
[1]('[2]', about_view, name='about'),
]The path function defines the URL pattern, and the string 'about/' specifies the URL path segment.
Fill all three blanks to create a URL pattern that maps 'contact/' to a view called 'contact_view' with the name 'contact'.
urlpatterns = [
[1]('[2]', [3], name='contact'),
]The path function defines the URL pattern, 'contact/' is the URL path, and contact_view is the view function handling the request.