> without the explicit newlines in file.write(i), could it be that the > file was closed before the write buffer was ever flushed? No because close() was called explicitly, which does a flush first... Alan G.