{% with ''|center:n as range %} {% for _ in range %} {{ forloop.counter }} {% endfor %} {% endwith %}
Here is what the above code is Doing:
1. It’s creating a list of numbers from 1 to n.
2. It’s iterating over that list.
3. It’s printing the value of the current item in the list.
The output of this code will be a list of numbers from 1 to n.