Simple looping with LaTeX
Here’s a fairly easy example how to loop through a LaTeX collection/list with the help of the pgffor package
\documentclass[12pt,ngerman]{scrartcl} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage{babel} \usepackage{pgffor} \begin{document} \begin{itemize} \foreach \x in {Donald,Dagobert,Gustav,Goofy} {\item \x} \end{itemize} \end{document}