The unlucky Ikta-kun has rewritten the important character string T that he had to a different character string T'by the virus. It is known that the virus has rewritten one letter of T to a different letter. That is, T and T'are different by exactly one character. In order to restore T, Ikta prepared a document S in which T appears. As a preparation for restoring T, I would like to find out the number of substrings of S that may match T.

Given the string T'and the document S. S = a1 a2 a3 .. .a | S | length | T'| substring ak ak + 1 ... ak + | T'| −1 (1 ≤ k ≤ | S | − | T'| Find the number of things that differ by one character from T'in +1).



Input

The input is given in the following format.


S
T'


* S is given in the first line.
* T'is given in the second line.
* S and T'consist only of uppercase and lowercase alphabets, respectively.



Constraints

Each variable being input satisfies the following constraints.

* 1 ≤ | S | ≤ 300,000
* 1 ≤ | T'| ≤ | S |

Output

Output the number of substrings that satisfy the conditions on one line.

Examples

Input

abcbcdbc
abc


Output

2


Input

aaaaaa
aaaaaa


Output

0


Input

baaaaaaaa
b


Output

8
#include <bits/stdc++.h>
using namespace std;

typedef long long ll;
typedef unsigned long long ull;
typedef pair<ll, ll> P;

#define fi first
#define se second
#define repl(i,a,b) for(ll i=(ll)(a);i<(ll)(b);i++)
#define rep(i,n) repl(i,0,n)
#define all(x) (x).begin(),(x).end()
#define dbg(x) cout<<#x"="<<x<<endl
#define mmax(x,y) (x>y?x:y)
#define mmin(x,y) (x<y?x:y)
#define maxch(x,y) x=mmax(x,y)
#define minch(x,y) x=mmin(x,y)
#define uni(x) x.erase(unique(all(x)),x.end())
#define exist(x,y) (find(all(x),y)!=x.end())
#define bcnt __builtin_popcountll

#define INF 1e16
#define B1 1000000007
#define B2 1000000009

ull mod_pow(ull a,ull n){
  ull res=1;
  while(n){
    if(n&1)res=res*a;
    a=a*a;
    n>>=1;
  }
  return res;
}

string S,T;
vector<ull> hs1,hs2;

int main(){
  cin.tie(0);
  ios::sync_with_stdio(false);

  cin>>S>>T;
  int N=S.size();
  int M=T.size();
  ull h1=0,h2=0;
  rep(i,M){
    h1*=B1;
    h1+=T[i];
    h2*=B2;
    h2+=T[i];
  }
  rep(i,M){
    ull p1=mod_pow(B1,M-1-i);
    ull p2=mod_pow(B2,M-1-i);
    repl(j,'a','z'+1){
      if(T[i]==j)continue;
      hs1.push_back(h1-p1*T[i]+p1*(ull)j);
      hs2.push_back(h2-p2*T[i]+p2*(ull)j);
    }
    repl(j,'A','Z'+1){
      if(T[i]==j)continue;
      hs1.push_back(h1-p1*T[i]+p1*(ull)j);
      hs2.push_back(h2-p2*T[i]+p2*(ull)j);
    }
  }
  sort(all(hs1)); uni(hs1);
  sort(all(hs2)); uni(hs2);

  h1=0; h2=0;
  ll res=0;
  ull elim1=mod_pow(B1,M),elim2=mod_pow(B2,M);
  rep(i,N){
    h1*=B1;
    h1+=S[i];
    h2*=B2;
    h2+=S[i];
    if(i>=M){
      h1-=elim1*S[i-M];
      h2-=elim2*S[i-M];
    }
    if(i>=M-1&&(*lower_bound(all(hs1),h1))==h1&&(*lower_bound(all(hs2),h2))==h2)res++;
  }
  cout<<res<<endl;

  return 0;
}

