C++ Early Termination 100%
Iteration with early termination.\n\ncpp []\nclass Solution {\npublic:\n    int minElement(vector<int>& nums) {\n        int min_sum = std::numeric_limits<int>:
Iteration with early termination.\n\n```cpp []\nclass Solution {\npublic:\n    int minElement(vector<int>& nums) {\n        int min_sum = std::numeric_limits<int>::max();\n        for (size_t i = 0; i != nums.size(); ++i) {\n            int sum = 0;\n            int val = nums[i];\n            while (val && sum < min_sum) {\n                sum += val % 10;\n                val /= 10;                \n            }   \n            min_sum = std::min(min_sum, sum);   \n        }\n        return min_sum;\n    }\n};\n```
['C++']