diff options
Diffstat (limited to 'readme.txt')
-rwxr-xr-x | readme.txt | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/readme.txt b/readme.txt new file mode 100755 index 0000000..af07ce4 --- /dev/null +++ b/readme.txt @@ -0,0 +1,38 @@ +Word Count Program
+Joe Robinson
+Java Test for Ensemble
+
+This program can be used to count the number of occurences of a word in a given file.
+
+It will not count words which are used again as part of longer words.
+
+E.g: "his" and "is" will not be counted if "this" is used.
+
+To run the program, run:
+
+java -jar WordCount.jar
+
+This will prompt you for a text file to count the words from. You can enter just the filename if it is in the same directory as WordCount.jar, or provide a full path to a file.
+
+You can also enter the filename as an argument, e.g:
+
+java -jar WordCount.jar test.txt
+
+Source code is located in src/com/ensemble/wordcount
+
+The file can be compiled and built with the following commands:
+
+javac -d classes src/com/ensemble/wordcount/*.java
+
+jar cvfm WordCount.jar manifest.txt classes/com/ensemble/wordcount/*.class
+
+Two example files are provided
+
+test.txt - the example line provided in the specification. The program will produce the same output as given in the specification.
+
+specification.txt - The specification for the program as provided by email.
+
+Known issue: Currently all punctuation is removed, as otherwise it was counting words with punctuation following them as a different word (e.g "maybe." would discard "maybe". This is not ideal as it would also remove punctuation in the middle of the words, and we probably only want to remove punctuation at the start/end of words. I considered this to be outside of the specification, as it would take some extra time to ensure this was handled properly, and it was not specified how or if this
+should be handled.
+
+Note: This has been tested on Linux and Windows systems, but should work on any system which can run Java.
|