python check if word is in list of strings