Concatenate the two arrays together and try to build a heap. If there's a collision on the comparison of any two strings while building the heap, you know that two strings are lexicographically...