On Dec 11, 8:58 am, MRAB <pyt...@mrabarnett.plus.com> wrote: > output = ['<html><head>'] > output.append('<title>My Page</title>') > output.append('</head><body>') > output.append('<h1>Powers of two</h1>\n<ol>') > for n in range(1, 11): > output.append('<li>%s</li>' % (2 ** n)) > > output.append('</ol></body></html>') > print ''.join(output)
Agreed (I might join on '\n' though), I was just trying to introduce as few new concepts as possible :) -- http://mail.python.org/mailman/listinfo/python-list