Below is the exercise 5 of nodeschool learnyounode module
Create a program that prints a list of files in a given directory, filtered by he extension of the files. You w
Here is what I came up with:
var fs = require('fs'); var filePath = process.argv[2]; var fileType = '.' + process.argv[3]; fs.readdir(filePath, function(err, list) { for(var i=0; i