Create a class called Word which has a static value WORD_SIZE equal to three, and an instance variable which is a String that represents the word. The constructor for the class should take a single String parameter which represents the word that to be stored. For example,
Word w = new Word("cat:);
Given an input file of words, read the words into an array from the file and display them in a GUI. The GUI should have a GridLayout with one row and two columns. The left column should display the words in the order read from the file, and the right column should display the words in sorted order (using Selection Sort).
As you are reading the words you should check that the value read in is legal (3 letters), and if it is not, print it to the console and do not put it in the array of Words.
The input file
Each line of the input file may contain several words separated by commas. You will need to use a StringTokenizer to separate out the individual words. So, an example of the input file would be:
cat
fat,hat,hello
the,cat,is,black