#include <bits/stdc++.h>
using namespace std;
const int kMaxl = 1e6 + 10;
char A[kMaxl], B[kMaxl];
int a[kMaxl];
int Res = 0, cnt = 0;
int main() {
  scanf("%s%s", A + 1, B + 1);
  int la = strlen(A + 1), lb = strlen(B + 1);
  for (register int i = 1; i <= la; ++i) {
    a[i] = a[i - 1];
    if (A[i] == '1') a[i]++;
  }
  for (register int i = 1; i <= lb; ++i)
    if (B[i] == '1') cnt++;
  for (int i = 1; i + lb - 1 <= la; ++i) {
    if (abs((a[i + lb - 1] - a[i - 1]) - cnt) % 2 == 0) Res++;
  }
  cout << Res;
  return 0;
}
