As mentioned above, join makes a single string out of all the elements in the list. If im guessing correctly, you want to make 1 array out of the 3 words arrays, then sort that entire array. Just do:
...
my @all_words = (@words, @words2, @words3);
my @sorted_words = sort @all_words;
...