avoid using endl to improve performance (by avoiding flushing)