About Question enthuware.ocpjp.v7.2.1583 :
Posted: Sun Sep 29, 2013 10:16 pm
Hi, Paul!
I want to ask, why
is wrong? I tested both this and the right answer :
and both ended printing the same result.
I want to ask, why
Code: Select all
File[] roots =File.listRoots();
for(File f:roots){
System.out.println(f);
}
Code: Select all
Iterable<Path>proots = FileSystems.getDefault().getRootDirectories();
for(Path p:proots){
System.out.println(p);
}