I have around 500 text files inside a directory with a same prefix in their filename say dailyReport_.
dailyReport_
The latter part of the file is the date of the fi
or in scala
new java.io.File(<>).listFiles.filter(_.getName.endsWith(".txt")).foreach(_.delete())