Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

import java.io.File;
import java.io.IOException;
import java.io.PrintStream;

public class Main {
    public static void main(String[] args) {
        File file = new File("C:\\temp\\debug.txt");
        try {
            PrintStream ps = new PrintStream(file);
            System.setOut(ps);
        } catch (IOException e) {
        }
        System.out.println("To File");
    }
}