#include <bits/stdc++.h>
using namespace std;
int dir[] = {0, 1, 0, -1, 1, 0, -1, 0};
void solve() {
  string s, t;
  cin >> s >> t;
  int sz = s.size(), tz = t.size();
  bool check = false;
  int cnt = 0;
  for (int i = 0; i <= sz - tz; i++) {
    bool flag = true;
    for (int j = 0; j < tz; j++) {
      if (s[i + j] != t[j]) {
        flag = false;
        break;
      }
    }
    if (flag) {
      cnt++;
      s[i + tz - 1] = '#';
    }
  }
  cout << cnt << endl;
}
int main() {
  ios_base::sync_with_stdio(0);
  int t = 1;
  for (int cn = 1; cn <= t; cn++) {
    solve();
  }
  return 0;
}
