Phrase Counter will return a list of the 100 most common three word sequences inside of .txt files
- Make sure you have Node installed on your computer, Link to download
- Open command line and navigate to this project's folder
- Run npm install
- Either pass in .txt file paths as arguments like so:
node ./index.js ./test-files/sandwiches.txt
(can handle multiple file paths seperated by spaces). Or pass in a .txt file path throught stdin like so:cat ./test-files/sandwiches.txt | node ./index.js
- I would have more robust unit tests and test every function
- I would make some type of greeting message and implement a file selector from the console
- I would make the output look better, maybe with some ascii art
- I would figure out a way to verify correct phrase count on large texts
- I would figure out a faster way to do the string manipulations in the beginning of getPhrases(), if possible
- I would figure out a way to prit the correct order without sorting the phrases map, if possible
- I would figure out how to get the console logs to show correctly when running the app in the docker container
- Counts words with unicode characters as seperate words rather than the same word without the unicode character