C++ | Easy Approach | 4 Lines of Code
\n# Approach\n Describe your approach to solving the problem. \nUsing to_string and stoi\n\n\n# Code\n\nclass Solution {\npublic:\n    long long findTheArrayCon
\n# Approach\n<!-- Describe your approach to solving the problem. -->\nUsing `to_string` and `stoi`\n\n\n# Code\n```\nclass Solution {\npublic:\n    long long findTheArrayConcVal(vector<int>& nums) {\n        long long n = size(nums), i = 0, j = n-1,ans = 0;\n         while(i<j)  ans += stoi((to_string(nums[i++])+to_string(nums[j--])));\n         if(i==j) ans+=(int)(nums[i]);\n         return ans;      \n    }\n};\n```
['C++']