Design a dictionary that supports adding words and searching them with a single-character wildcard.
addWord(word)stores a word.search(pattern)returnstrueif any stored word matches the pattern. The pattern may contain., which matches any one character.
Implement addAndSearchWords(operations) where operations is a list of [op, ...args]: ["addWord", word] and ["search", pattern]. Return one result per operation - null for addWord, a boolean for search.