package chapter7;

import java.io.File;

public class Example03 {
    public static void main(String[] args) {
        File file = new File("src/chapter7");
        if (file.isDirectory()) {
            System.out.println("是目录");
            String[] names = file.list();
            for (String name : names) {
                System.out.println(name);
            }
        }
    }
}
