>>> import albatross
>>> ctx = albatross.SimpleContext('.')
>>> albatross.Template(ctx, '<magic>', '''
... <al-exec expr="
... results = []
... for n in range(2, 10):
...     for x in range(2, n):
...         if n % x == 0:
...            results.append('%d equals %d * %d' % (n, x, n/x))
...            break
...     else:
...          results.append('%d is a prime number' % n)
... ">
... <al-for iter="l" expr="results">
...  <al-value expr="l.value()" whitespace>
... </al-for>
... ''').to_html(ctx)
>>> ctx.flush_content()
2 is a prime number
3 is a prime number
4 equals 2 * 2
5 is a prime number
6 equals 2 * 3
7 is a prime number
8 equals 2 * 4
9 equals 3 * 3
