You can have the line break appended at the end by using the three-arg version of mkString:
(header :: rows).mkString("", "\n", "\n")
My two cents: I prefer the second solution. Maybe it's because I have never programmed in Java.