Printing a new line is …
System.out.print(“\n”); You may feel a joke here.
try {
bw = new BufferedWriter(new FileWriter(new File("hello.txt")));
bw.write("helo world" + "\r\n");
bw.write("hello world 2");
bw.flush();
bw.close();
} catch (IOException ex) {
ex.printStackTrace();
}
No comments:
Post a Comment