Loading...
Design a data structure that supports adding words and searching with '.' wildcards (matches any letter).
Input: Line 1: comma-separated operations (add/search). Line 2: comma-separated arguments. Output: Result of each search operation, one per line.
add,add,search,search,search,search bad,dad,.ad,b..,b.d,b..
True True True True