#include <bits/stdc++.h>
using namespace std;
vector<int> L;
int main() {
  ios_base::sync_with_stdio(0);
  int n, l;
  unsigned long long int sum, mx, minx, ans, ul, ll;
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> l;
    L.push_back(l);
  }
  sort(L.begin(), L.end());
  sum = 0;
  for (int i = 0; i < n - 1; i++) sum += L[i];
  mx = max(sum, (unsigned long long int)L[n - 1]);
  minx = min(sum, (unsigned long long int)L[n - 1]);
  ul = sum + L[n - 1];
  ul--;
  ll = mx - minx;
  ll++;
  cout << min(ll, ul) << "\n";
  return 0;
}
