from collections import defaultdict import sys from typing import Counter readline=sys.stdin.readline write=sys.stdout.write from math import gcd as GCD import math S=readline().rstrip() T=readline().rstrip() ans=S.count(T) print(ans)