#include <bits/stdc++.h>
using namespace std;
int n, m, t, o, s;
char A[1000005], B[1000005];
int main() {
  scanf("%s", A);
  scanf("%s", B);
  n = strlen(A);
  m = strlen(B);
  for (int i = 0; i < m - 1; i++) t ^= (B[i] != B[i + 1]);
  for (int i = 0; i < m; i++) o ^= (B[i] ^ A[i]);
  if (o % 2 == 0) s++;
  for (int i = 1; i <= n - m; i++) {
    o ^= (A[i - 1] ^ B[0]);
    o ^= (A[i + m - 1] ^ B[m - 1]);
    o ^= t;
    if (o % 2 == 0) s++;
  }
  cout << s << endl;
}
