[Tex/LaTex] Hide closing statements for algorithms

algorithms

I would like to generate an algorithm with the algorithmic package which does not show the annoying closing statements when I typeset it. I have done this before but have now forgotten how to do it. Specifically,

   \FORALL Natural numbers N
      \STATE N=N-1 !
   \ENDFOR

I'd prefer that the final \ENDFOR statement not show up after typesetting as this just needlessly chews up space.

Best Answer

From the algorithmic manual:

There is a single option, noend that may be invoked when the algorithmic package is loaded. With this option invoked the end statements are omitted in the output. This allows space to be saved in the output document when this is an issue.

So, if you load the package with

\usepackage[noend]{algorithmic}

there won't be any closing statements.