#include <bits/stdc++.h>
using namespace std;
int main() {
  string s, t;
  cin >> s >> t;
  int o = s.find(t);
  int c = 0;
  while (o != -1) {
    c++;
    o = s.find(t, o + t.length());
  }
  cout << c << endl;
}
