#include <bits/stdc++.h>
using namespace std;
string s, t;
int n, m, sum, ans;
int f[1000010];
int main() {
  cin >> s >> t;
  n = s.size();
  m = t.size();
  s = '\0' + s;
  t = '\0' + t;
  for (int i = 1; i <= n; i++) f[i] = f[i - 1] + (s[i] == '1');
  for (int i = 1; i <= m; i++) sum += (t[i] == '1');
  for (int i = 1; i <= n - m + 1; i++) {
    if ((f[i + m - 1] - f[i - 1]) % 2 == sum % 2) ans++;
  }
  cout << ans << endl;
  return 0;
}
