public ArrayList<Object> alphabeticSort(String[] words){

        this.words = words;
        this.nWords = words.length;

        this.sortedWords = new String[this.nWords];
        for(int i=0; i<this.nWords; i++)this.sortedWords[i] = this.words[i];

        this.alphabeticSortIndices(words);

        for(int i=0; i<this.nWords; i++){
            sortedWords[i] = words[wordOrder[i]];
        }

        ArrayList<Object> ret = new ArrayList<Object>();
        ret.add(sortedWords);
        ret.add(wordOrder);

        return ret;
    }