added sort-words function (maybe onter old stuff too