def print_list(list_name, list_to_print):
    """
    Print all the contents of a list.
    :param list_name: The name of the list.
    :param list_to_print: The list to be printed.
    :return: The string to be submitted to the user.
    """
    string = ""
    for entry in list_to_print:
        string += entry + "\n"

    return f"""
Printing {list_name} list.
```
{string}
```
"""