I have seen this question but I still disable the numbering of algorithms.
I have the following code:
\begin{algorithm}
\caption{\textsc{FizzBuzz}}
\begin{algorithmic}
\FOR{$i \Leftarrow 1 \ldots 100$}
\IF{$i$ \emph{mod} $3 = 0 \wedge i$ \emph{mod} $5 = 0$}
\item \textsc{Print}(``FizzBuzz")
\ELSIF{$i$ \emph{mod} $3 = 0$}
\item \textsc{Print}(``Fizz")
\ELSIF{$i$ \emph{mod} $5 = 0$}
\item \textsc{Print}(``Buzz")
\ELSE
\item \textsc{Print}($i$)
\ENDIF
\ENDFOR
\end{algorithmic}
\end{algorithm}
It renders the following:
I want to get rid of the part that says Algorithm 1
. The answer to the question referenced above basically said to change \caption{\textsc{FizzBuzz}}
to \caption*{\textsc{FizzBuzz}}
, but when I do that the following is rendered:
This offers different algorithm numbering, but I want to disable numbering altogether and keep my caption. Can anybody help me?
Best Answer
Load the
caption
package, then the starred variant of\caption
becomes available. The reason a star shows up in the output now is due to a specific implementation of starred commands in LaTeX.By the way, the
caption
package will also allow you to customize the format of captions, and you won't need\textsc
every time then.