c++ sol.
Intuition\n Describe your first thoughts on how to solve this problem. \n\n# Approach\n Describe your approach to solving the problem. \n\n# Complexity\n- Time 
# Intuition\n<!-- Describe your first thoughts on how to solve this problem. -->\n\n# Approach\n<!-- Describe your approach to solving the problem. -->\n\n# Complexity\n- Time complexity:\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\n\n- Space complexity:\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```\nclass WordDictionary {\npublic:\n    vector<string> v;\n    WordDictionary() {\n        \n    }\n    \n    void addWord(string word) {\n        v.push_back(word);\n    }\n    \n    bool search(string word) {\n        int count=0;\n        int n=word.size();\n        for(int i=0; i<v.size(); i++){\n            if(n==v[i].size()){\n                for(int j=0; j<n; j++){\n                    if(v[i][j]==word[j]||word[j]==\'.\'){\n                        count++;\n                    }\n                    else{\n                        count=0;\n                        break;\n                    }\n                }\n                if(count==n) return true;\n            }\n        }\n        return false;\n    }\n};\n\n/**\n * Your WordDictionary object will be instantiated and called as such:\n * WordDictionary* obj = new WordDictionary();\n * obj->addWord(word);\n * bool param_2 = obj->search(word);\n */\n```
['C++']