<!---->
<xslt:transform xmlns:loop="http://informatik.hu-berlin.de/loop" xmlns:xslt="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xslt:output method="text" />
<xslt:param name="bound" select="1000" />
<xslt:template match="/">
<xslt:text />Prime Numbers (2 - <xslt:value-of select="$bound" />
<xslt:text>)
2</xslt:text>
<loop:for name="i" from="3" to="$bound" step="2">
<xslt:variable name="j" select="2" />
<xslt:variable name="is-prime">
<loop:while test="$j*$j <= $i">
<loop:do>
<xslt:if test="$i mod $j = 0">.</xslt:if>
</loop:do>
<loop:update name="j" select="$j+1" />
</loop:while>
</xslt:variable>
<xslt:if test="$is-prime=''">
<xslt:text />, <xslt:value-of select="$i" />
</xslt:if>
</loop:for>
<xslt:text>
</xslt:text>
</xslt:template>
</xslt:transform>