Implement various classes of io package using Java in NetBeans

//Program 1
import java.io.BufferedInputStream;
import java.io.FileInputStream;
import java.io.IOException;
public class Practical_37{
    public static void main(String args[]) throws IOException{
        FileInputStream fin = new FileInputStream("file1.txt");
        BufferedInputStream bin = new BufferedInputStream(fin);
        System.out.println("Number of remaining bytes:" +bin.available());
        boolean b=bin.markSupported();
        if (b){
            bin.mark(bin.available());
        }
        bin.skip(4);
        System.out.println("FileContents :");
        int ch;
        while ((ch=bin.read()) != -1){
            System.out.print((char)ch);
        }
        bin.reset();
        while ((ch=bin.read()) != -1){
            System.out.print((char)ch);
        }
        fin.close();
    }
}

//Program 2
import java.io.File;
import java.io.FileWriter;
import java.io.IOException;
import java.util.logging.Level;
import java.util.logging.Logger;
import java.util.Scanner;

public class practical37 {

    public static void main(String[] args) {
        File myfile = new File("File37.txt");
        try {
            myfile.createNewFile();
            System.out.println("File iS created Succsfully.......");
        } catch (IOException ex) {
            Logger.getLogger(practical37.class.getName()).log(Level.SEVERE, null, ex);
        }

        System.out.println("Writing On File........");
        try {
            FileWriter fileWriter = new FileWriter("File37.txt");
            fileWriter.write("I am Bot I was Created BY Ravan\nRavan Helping me to Upgading....");
            fileWriter.close();
            System.out.println("File Write Succsufully.........");
        } catch (IOException ex) {
            Logger.getLogger(practical37.class.getName()).log(Level.SEVERE, null, ex);
        }

        System.out.println("Reading File37.txt");

        File myFile = new File("File37.txt");
        try {
            Scanner sc = new Scanner(myFile);
            while (sc.hasNextLine()) {
                String line = sc.nextLine();
                System.out.println(line);
            }
            sc.close();
        } catch (Exception e) {
            System.out.println("Exception Occuring..........");
        }
        File myfFile = new File("File37.txt");
        if (myFile.delete()) {
            System.out.println("File deleted..");
        }
    }
}

//NOT TESTED