#include <bits/stdc++.h>
using namespace std;
int ans;
string s1, s2;
int c;
int g;
int main() {
  cin >> s1 >> s2;
  int l = s2.length();
  for (int i = 0; i < l; i++)
    if (s2[i] == '1') g++;
  for (int i = 0; i < l; i++)
    if (s1[i] == '1') c++;
  if (g % 2 == c % 2) ans++;
  for (int i = 1; i <= s1.length() - l; i++) {
    if (s1[i - 1] == '0' && s1[i + l - 1] == '1') c++;
    if (s1[i - 1] == '1' && s1[i + l - 1] == '0') c--;
    if (g % 2 == c % 2) ans++;
  }
  cout << ans << endl;
  return 0;
}
