当前位置: 技术问答>java相关
极其简单的送分问题!!!!!!!!欢迎来拿分
来源: 互联网 发布时间:2015-03-02
本文导语: import java.io.*; public class DirList { public static void main(String[] args) { try { File path = new File("."); //(1) String[] list; if(args.length == 0) list = pa...
import java.io.*;
public class DirList {
public static void main(String[] args) {
try {
File path = new File("."); //(1)
String[] list;
if(args.length == 0)
list = path.list();
else
list = path.list(new DirFilter(args[0]));
for(int i = 0; i
public class DirList {
public static void main(String[] args) {
try {
File path = new File("."); //(1)
String[] list;
if(args.length == 0)
list = path.list();
else
list = path.list(new DirFilter(args[0]));
for(int i = 0; i