I'm getting "Oops, try again. Does your censor function take exactly two arguments, a text string and a word to replace with asterisks? Your code threw a "list indices must be integers, not str" error." Anyone can help me spot the error here? Thanks!
def censor(text, word): strings = text.split() for i in strings: if i == word: strings[i] = len(word) * "*" return " ".join(strings)