Requirements - Use only standard Java API and no apache file utils for this.
Most of the answers I found on the internet either dont meet this requirement or load all file names into an array which can consume too much memory when no. of files = 20,000+
Please suggest how I can do this. Is there also a way to keep track of new files that were added during the execution of the loop in this code ?
My name was Borat Sagdiyev. But the forum does not allow such names.