Computer scienceBackendDjangoTemplates

Template filters

To-Do list

Report a typo

Assume that you pass the following context to a template:

todos = ['take a nap', 'get a coffee', 'learn a topic on the Hyperskill']

Find out how many tasks you need to do, and render them with the join filter with an additional <br/> argument.

Write a program in Python 3
template = """
<html>
<div> You have {{ ... }} tasks to do: </div>
<div> {{ ... }} </div>
</html>
"""
___

Create a free account to access the full topic