#include <bits/stdc++.h>
#pragma comment(linker, "/STACK:66777216")
using namespace std;
const double EPS = 1e-10;
const double PI = acos(-1.0);
const int INF = (int)2e9 + 7;
const long long LINF = (long long)8e18;
const long long MM = (long long)1e9 + 7;
const int MAXN = (int)1e3 + 7;
const int MAXC = (int)20;
int solve();
int main() {
  srand(atoi("Korob, please die"));
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  solve();
  return 0;
}
int solve() {
  int n;
  cin >> n;
  long long sm = 0;
  vector<int> T;
  for (int i = 0; i < (int)n; i++) {
    int q;
    cin >> q;
    T.push_back(q);
    sm += q;
  }
  long long ans = -1;
  for (int i = 0; i < (int)n; i++) {
    ans = max(ans, T[i] - (sm - T[i]) + 1);
  }
  cout << ans;
  return 0;
}
