Given two sentences as strings, write an alogrithm (with the least time complexity) to find the number of occurances of each word of string1 in string2.
string1: Cat eats rat.
string2: Tiger belongs to cat family but it's strange that tiger eats cat.
cat - 2
eats - 1
rat - 0