#include <bits/stdc++.h>
using namespace std;
char ch[1001000];
char chs[1001000];
int ans[1001000];
int main() {
  cin >> ch;
  cin >> chs;
  int len = strlen(ch);
  memset(ans, 0, sizeof(ans));
  for (int i = 0; i < len; i++) {
    ans[i] = ans[i - 1];
    if (ch[i] == '1') ans[i]++;
  }
  int lens = strlen(chs);
  int sum = 0;
  for (int i = 0; i < lens; i++) {
    if (chs[i] == '1') sum++;
  }
  int num = 0;
  if ((ans[lens - 1]) % 2 == sum % 2) num++;
  for (int i = 1; i < len; i++) {
    if (i + lens - 1 >= len) break;
    int hh = ans[i + lens - 1] - ans[i - 1];
    if (hh % 2 == sum % 2) num++;
  }
  cout << num << endl;
  return 0;
}
