Sponsored
Use these hints if you're stuck. Try solving on your own first.
Notice that, after sorting both arrays, there should be a one-to-one correspondence between every element.
Thus <code>x = min(nums2) - min(nums1)</code>.
Solve with full IDE support and test cases