#include <bits/stdc++.h>
using namespace std;
string str1, str2;
long long i = 0, j = 0, n, cnt1 = 0, cnt2 = 0, ans = 0;
int main(void) {
  ios_base::sync_with_stdio(false), cin.tie(0), cout.tie(0);
  srand(time(NULL));
  ;
  cin >> str1 >> str2;
  for (i = 0; i < str2.length(); i++) {
    if (str2[i] == '1') cnt2++;
  }
  for (i = 0; i < str1.length(); i++) {
    if (str1[i] == '1') cnt1++;
    if (i >= str2.length()) cnt1 -= (str1[i - str2.length()] == '1');
    if (i >= (str2.length() - 1)) {
      if (abs(cnt1 - cnt2) % 2 == 0) ans++;
    }
  }
  cout << ans;
  return 0;
}
