Question: It is possible to use the File class to list the contents of the current working directory.
By: AshQuestion: It is possible to use the File class to list the contents of the current working directory.
Answer:True. The code below shows how this is done.
1. File f = new File(".");
2. String contents = f.list();
Most Viewed Articles (in Certification )
Latest Articles (in Certification)
Comment on this tutorial
- Data Science
- Cloud Computing
- Java Beans
- Mac OS X
- Office 365
- Tech Reviews