#include <bits/stdc++.h>
using namespace std;
int main() {
  string a, b;
  cin >> a >> b;
  long long s1 = 0, s2 = 0;
  for (long long i = 0; i < b.size(); i++) {
    if (b[i] == '1') s1++;
    if (a[i] == '1') s2++;
  }
  long long ans = 0;
  for (long long i = 0; i <= a.size() - b.size(); i++) {
    if (i == 0) {
      if (s1 % 2 == s2 % 2) ans++;
    } else {
      if (a[i - 1] == '1') s2--;
      if (a[i + b.size() - 1] == '1') s2++;
      if (s1 % 2 == s2 % 2) ans++;
    }
  }
  cout << ans;
}
