Swift, 3 ms Beats 100.00%, nums2(min) - nums1[0,1,2], two pointer
Code

# Code
```swift []
class Solution {
    func minimumAddedInteger(_ nums1: [Int], _ nums2: [Int]) -> Int {
        let arr1 = nums1.sorted()
        let arr2 = nums2.sorted()
        var ans = [Int]()
        
        for i in 0..<min(3, arr1.count) {
            var count_error = 0
            let diff = arr2[0] - arr1[i]
            
            var ind1 = 0, ind2 = 0
            while ind2 < arr2.count && ind1 < arr1.count && count_error < 3 {
                if arr1[ind1] + diff == arr2[ind2] {
                    ind1 += 1
                    ind2 += 1
                } else {
                    count_error += 1
                    ind1 += 1
                }
            }
            if count_error < 3 {
                ans.append(diff)
            }
        }
        
        ans.sort()
        return ans[0]
    }
}

```
['Array', 'Two Pointers', 'Swift', 'Python', 'Python3']