solve by hash table
Intuition\n Describe your first thoughts on how to solve this problem. \n\n# Approach\n Describe your approach to solving the problem. \n\n# Complexity\n- Time 
# Intuition\n<!-- Describe your first thoughts on how to solve this problem. -->\n\n# Approach\n<!-- Describe your approach to solving the problem. -->\n\n# Complexity\n- Time complexity: $$O(n^2)$$\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\n\n- Space complexity: $$O(n)$$\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```cpp []\nclass Solution {\npublic:\n    int minimumAddedInteger(vector<int>& nums1, vector<int>& nums2) {\n        unordered_map<int, int> mp, mp3;\n        int mx = 0, ans = 0;\n        for(auto i : nums2) mp3[i]++;\n        for(int i = 0;i < nums2.size();i++){\n            unordered_map<int, int> mp2;\n            for(int j = 0;j < nums1.size();j++){\n                mp2[nums1[j]]++;\n                if(mp2[nums1[j]] <= mp3[nums2[i]]){\n                    mp[nums2[i] - nums1[j]]++;\n                }\n            }\n        }\n        \n        for(auto i : mp){\n            if(i.second > mx){\n                mx = i.second;\n                ans = i.first;\n            }\n            if(i.second == mx){\n                ans = (i.first < ans)? i.first : ans;\n            }\n        }\n        return ans;\n    }\n};\n\nauto init = []()\n{ \n    ios::sync_with_stdio(0);\n    cin.tie(0);\n    cout.tie(0);\n    return \'c\';\n}();\n```
['Array', 'Hash Table', 'C++']