you ould simplify this: ``$output->write()`` accepts an arrat of lines too