First (untested) implementation of the print/flush