More tweaking to get the output correct.