What if the two arrays share elements?

  • 0

    I have read several solutions to the problem. It seems that most solutions does not consider the situation when the two arrays share elements? Any insight on that?

  • 0

    Maybe it just doesn't matter? Just because there's no special code for this, doesn't mean the code can't handle it. And I'm pretty sure that the OJ does have test cases with shared and duplicate elements.

Log in to reply

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.