Rule: Iterating expressions with xsl:for-each is generally bad style.
You can typically do every xsl:for-each with an xsl:apply-templates action.
But you might need modes...
And maybe named templates...
These will are explained in the adjoining slides.