Ordering Strings of Varying Length Lexicographically