FileWriter. WRITE to a file
public class Main {
public static void main(String[] args) {
try {
FileWriter writer = new FileWriter("Foo.txt");
writer.write("Hello foo!@");
writer.close();
} catch (IOException ex) {}
}
}