C++ Solution
Synopsis:\n\nUse a varation of Kadane\'s Algorithm to find the maximum subarray sum with one deletion:\n\n Calculate the max sub-array sums in forward (left -> 
**Synopsis:**\n\nUse a varation of [Kadane\'s Algorithm](https://en.wikipedia.org/wiki/Maximum_subarray_problem#Kadane\'s_algorithm) to find the maximum subarray sum with one deletion:\n\n* Calculate the max sub-array sums in forward (left -> right) and reverse (right -> left) directions\n    * the forward max sub-array sums for each i-th index represents the max sub-array sum *ending* at index i\n    * the reverse max sub-array sums for each i-th index represents the max sub-array sum *beginning* at index i\n\n* While calculating the sums also keep track of the max sub-array sum with no deletions (this can be done in either the forward or reverse directions, I arbitrarily chose to perform this check in the forward direction)\n\n* Iterate once through the array and use pre-calculated sums to check if there exists a larger sum with one deletion\n\n**Runtime:** O(N)\n\n```\nclass Solution {\npublic:\n    static constexpr auto INF = static_cast<int>(1e4+1);\n    using VI = vector<int>;\n    int maximumSum(VI& A, int sum=0, int ans=-INF) {\n        auto N = static_cast<int>(A.size());\n        VI end(N), beg(N);\n        end[0] = sum = ans = A[0]; // forward\n        for (auto i=1; i < N; ++i) {\n            end[i] = sum = max(A[i], sum + A[i]); // new sub-array or append to existing sub-array, whichever is maximal\n            ans = max(ans, sum); // max sub-array sum with no deletions\n        }\n        beg[N-1] = sum = A[N-1]; // reverse\n        for (auto i=N-2; i >= 0; --i) { \n            beg[i] = sum = max(A[i], sum + A[i]); // new sub-array or append to existing sub-array, whichever is maximal\n        }\n        for (auto i=1; i+1 < N; ++i) { // use pre-calculated sums to check if there exists a larger sum with one deletion\n            sum = end[i-1] + beg[i+1]; // "delete" i-th value\n            ans = max(ans, sum);\n        }\n        return ans;\n    }\n};\n```\n\n**Naive Algorithm:**\n\n* Calculate the sum of each sum-array of size k from 1 to N inclusive and return the maximum sum\n* If k is greater than 1, then optionally delete the smallest negative number from the sub-array sum\n\n**Runtime:** O(N^2)\n\n```\nclass Solution {\npublic:\n    static constexpr auto INF = static_cast<int>(1e4+1);\n    int maximumSum(vector<int>& A, int ans=-INF) {\n        auto N = static_cast<int>(A.size());\n        for (auto k=1; k <= N; ++k) {\n            for (auto i=0; i <= N-k; ++i) {\n                auto beg = A.begin() + i,\n                     end = A.begin() + i + k;\n                auto sum = accumulate(beg, end, 0),\n                     min = *min_element(beg, end);\n                if (k > 1 && min < 0) {\n                    sum -= min; // "remove" minimum negative number from the sum\n                }\n                ans = max(ans, sum);\n            }\n        }\n        return ans;\n    }\n};\n```
[]