S = input() T = input() result = 0 p = 0 while True: p = S.find(T, p) if p == -1: break p = p + len(T) - 1 result += 1 print(result)