Groovy write to file (newline)

前端 未结 5 1533
你的背包
你的背包 2020-12-24 01:05

I created a small function that simply writes text to a file, but I am having issues making it write each piece of information to a new line. Can someone explain why it puts

5条回答
  •  粉色の甜心
    2020-12-24 01:50

    @Comment for ID:14. It's for me rather easier to write:

    out.append it
    

    instead of

    out.println it
    

    println did on my machine only write the first file of the ArrayList, with append I get the whole List written into the file.

    Kindly anyway for the quick-and-dirty-solution.

提交回复
热议问题