Mask banned word
Your task
A moderation filter masks a banned word. Given a message and a non-empty banned word, replace every occurrence of the banned word with asterisks of the same length. Matching is case-sensitive; scan left to right, and after masking an occurrence continue scanning right after it (matches never overlap). For example, censoring 'magic' in 'say the magic word, magic!' gives 'say the ***** word, *****!'.
Examples
censor(message: str, banned: str) -> strExample 1
Input
censor("say the magic word, magic!", "magic")Output
"say the ***** word, *****!"