#include <bits/stdc++.h>
using namespace std;
vector<char> prime(100000 + 1, true);
void sieve(long long int n) {
  prime[0] = prime[1] = false;
  for (long long int i = 2; i <= n; ++i) {
    if (prime[i]) {
      for (long long int j = 2 * i; j <= n; j += i) {
        prime[j] = false;
      }
    }
  }
}
void init(long long int ar[], long long int n, long long int val) {
  long long int i;
  for (i = 0; i < n; i++) {
    ar[i] = val;
  }
}
vector<long long int> v1;
vector<bool> visit;
vector<vector<long long int> > g;
vector<vector<long long int> > g1;
vector<long long int> ar;
vector<vector<long long int> > final;
vector<long long int> mind;
long long int c;
void dfs(long long int i, long long int n) {
  visit[i] = true;
  long long int j, k;
  for (j = 0; j < g[i].size(); j++) {
    if (!visit[g[i][j]]) {
      dfs(g[i][j], n);
    }
  }
  v1.push_back(i);
}
void dfs1(long long int i, long long int n, long long int len) {
  visit[i] = true;
  long long int j, k;
  final[len].push_back(i);
  mind[len] = min(mind[len], ar[i]);
  for (j = 0; j < g1[i].size(); j++) {
    if (!visit[g1[i][j]]) {
      dfs1(g1[i][j], n, len);
    }
  }
}
int main() {
  long long int n;
  cin >> n;
  long long int a[n];
  long long int i;
  for (i = 0; i < n; i++) cin >> a[i];
  long long int sum[n];
  sum[0] = a[0];
  for (i = 1; i < n; i++) sum[i] = sum[i - 1] + a[i];
  long long int cnt = 0;
  for (i = 0; i < n - 1; i++) {
    if (sum[i] == sum[n - 1] - sum[i]) cnt++;
  }
  cout << cnt << endl;
  return 0;
}
