
Antwort1
Eine einfache Möglichkeit hierfür ist die Verwendung des enumitem
Pakets zum Erstellen verschachtelter Listen. Der Trick, die Liste in einer neuen Zeile zu beginnen, ist adaptiert vondiese Antwort. Dies ist nicht erforderlich, wenn jedes Element Text enthält, aber erforderlich, wenn ein Schritt direkt als Element der Liste eingebettet wird. Wenn ein Schritt niemals auf diese Weise eingebettet wird, before={\apptocmd{\item}{\mbox{}}{}{}}
ist der Code nicht erforderlich.
\documentclass{article}
\usepackage{enumitem}
\usepackage{etoolbox}
\newlist{algolist}{enumerate}{3}
\setlist*[algolist]{leftmargin=*,before={\apptocmd{\item}{\mbox{}}{}{}}}
\setlist*[algolist,1]{label={\itshape Step \arabic*:}}
\setlist*[algolist,2]{label={\itshape Step \arabic{algolisti}.\arabic*:}}
\setlist*[algolist,3]{label={\itshape Step \arabic{algolisti}.\arabic{algolistii}.\arabic*:}}
\begin{document}
\begin{algolist}
\item This is the first step of the algorithm. It can have many lines in it and they will wrap as you would expect.
\item This is the second step of the algorithm.
\begin{algolist}
\item This is the first substep of the second step of the algorithm.
\item This is the second substep of the second step of the algorithm.
\begin{algolist}
\item This is the first substep of the second substep of the algorithm.
\item This is the second substep of the second substep of the algorithm.
\end{algolist}
\end{algolist}
\end{algolist}
\end{document}