#include <bits/stdc++.h>
using namespace std;
int i, n, a[1000010], p, q, ans;
inline int read() {
  int x = 0, f = 1;
  char ch = '\0';
  while (ch < '0' || ch > '9') f = (ch == '-') ? (0 - f) : f, ch = getchar();
  while (ch >= '0' && ch <= '9') x = x * 10 + (ch ^ '0'), ch = getchar();
  return x * f;
}
int main() {
  n = read();
  for (i = 1; i <= n; i++) a[i] = read(), q += a[i];
  for (i = 1; i <= n - 1; i++)
    p += a[i], q -= a[i], ans = (p == q) ? ans + 1 : ans;
  printf("%d\n", ans);
  return 0;
}
