#!/usr/bin/python

a=raw_input("Enter the larger string whose substring needs to be matched\n")
b=raw_input("Enter the smaller string\n")
blen=len(b)
count=0


# traverse through the letter of larger string
for i in range(0,len(a)):
	
	# check if the string with length of smaller string(a[i:i+blen] matches the smaller string
	if (a[i:i+blen]==b):	
		count+=1

#this would print the count of substrings of larger string
print count


### Input a-> vanivani b-> vani count->2
