#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  int num[100005];
  long long int sum = 0;
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> num[i];
    sum += num[i];
  }
  if (sum % 2 != 0) {
    cout << 0 << endl;
  } else {
    int ans = 0;
    long long int total = 0;
    long long int mid = sum / 2;
    for (int i = 0; i < n - 1; i++) {
      total = total + num[i];
      if (total == mid) ans++;
    }
    cout << ans << endl;
  }
}
