sort a set of text lines into alphabetic order