So when I write to my text file using FileOutputSstream I have used both
fos.write(("0"+"\n").getBytes());
and
fos.write(System.getProperty("line.separator").getBytes());
and neither of them work… they still print on the same line…
Any thoughts?
use a PrintStream
System.out is a PrintStream for example.
You say you have a FileOutputStream. Then,
also you can use;