Algoritmo eficiente para determinar si dos conjuntos de números son disjuntos
Practicando para entrevistas con desarrolladores de software y me quedé atrapado en una pregunta de algoritmo.
Given two sets of unsorted integers with array of length m and other of
length n and where m < n find an efficient algorithm to determine if
the sets are disjoint. I've found solutions in O(nm) time, but haven't
found any that are more efficient than this, such as in O(n log m) time.