Simple C++ answer for dummies like me
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:\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\n\n- Space complexity:\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```\nclass Solution {\npublic:\n    long long minSum(vector<int>& nums1, vector<int>& nums2) {\n        long s1 = 0, c1 = 0, s2 = 0, c2 = 0;\n        for (auto n : nums1)\n        {\n            s1 += n;\n            if (n == 0) c1 += 1;\n        }\n        for (auto n : nums2)\n        {\n            s2 += n;\n            if (n == 0) c2 += 1;\n        }\n        if (s1 < s2)\n        {\n            swap(s1, s2);\n            swap(c1, c2);\n        }\n        if (s1 == s2)\n        {\n            if ((c1 == 0 && c2 != 0) || (c2 == 0 && c1 != 0)) return -1;\n            return s1 + max(c1, c2);\n        }\n        if ((c1 == 0 && s1 + c1 < s2 + c2) || (c2 == 0 && s1 > s2)) return -1;\n        return max(s1 + c1, s2 + c2); \n    }\n};\n```
['C++']