What version of Excel are you using?
I suggest that you update your
Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)
How about
Excel Formula:
=IF(AND(H8="animal",OR(C8={"dog","cat"})),1,0)