How do I print a list as text with text in between the list items?

I need to figure out how to take a list, print it, and then have dividing text which correlates to the specific list item. Does anyone know how to do something like this?

Show an example of what you mean.

When you say print, do you mean display on screen ?

That sounds like YAML.

Search this board.

print as in display the text on-screen, yes.