I have two integer arrays with no info on range of the elements in the arrays. All i know is the lengths of two arrays m and n. Now there are some duplicates in both the arrays. I want to find the lowest common duplicate from both the arrays. Assume that i have limited memory, how do i solve this?
Share
May be MergeSort Algorithm can help you for solving this problem. MergeSort Algorithm is basically for sorting the elements in a list but its main crux is in its Divide and Conquer Approach. As you have mentioned that the memory is limited, hence Divide and Conquer seems to be a reasonable approach for solving the problem.