#include <bits/stdc++.h>
using namespace std;
const int MAXN = 1000005;
int la, lb, sum[MAXN], ans, cnt;
char a[MAXN], b[MAXN];
int main() {
  scanf("%s%s", a + 1, b + 1);
  la = strlen(a + 1), lb = strlen(b + 1);
  for (int i = 1; i <= lb; i++)
    if (a[i] != b[i]) cnt++;
  for (int i = 1; i <= la; i++) {
    sum[i] = sum[i - 1];
    if (a[i] == a[i - 1]) sum[i]++;
  }
  if (cnt % 2 == 0) ans++;
  for (int i = 2; i + lb - 1 <= la; i++) {
    int j = i + lb - 1, t = sum[j] - sum[i - 1];
    cnt = (cnt + lb - t) % 2;
    if (!cnt) ans++;
  }
  printf("%d\n", ans);
}
