#include <bits/stdc++.h>
using namespace std;
int main() {
  cin.tie(0);
  long long int n;
  cin >> n;
  long long int a[n], count = 0;
  for (int k = 0; k < (n); ++k) cin >> a[k];
  long long int sum = 0, sum1 = 0;
  for (long long int i = 0; i < n; i++) {
    sum += a[i];
  }
  for (long long int i = 0; i < n - 1; i++) {
    sum -= a[i];
    sum1 += a[i];
    if (sum1 == sum) count++;
  }
  cout << count;
  return 0;
}
