[beginner friendly][easy understanding][c++]
\nclass Solution {\npublic:\n    int countConsistentStrings(string allowed, vector<string>& words) {\n        int cnt = 0;\n        int alpha[26] = {0};\n      
```\nclass Solution {\npublic:\n    int countConsistentStrings(string allowed, vector<string>& words) {\n        int cnt = 0;\n        int alpha[26] = {0};\n        \n        for (char c: allowed)\n            alpha[c-\'a\'] = 1;\n        \n        bool found = true;\n\t\t\n        for (string str: words) {\n            for (char c: str) \n                if (alpha[c-\'a\'] == 0) {\n                    found = false;\n                    break;\n                }\n            \n            if (found)\n                cnt++;\n            found = true;\n        }\n\t\t\n        return cnt;\n    }\n};\n```\n**Feel free to ask any question in the comment section.**\nI hope that you\'ve found the solution useful.\nIn that case, **please do upvote and encourage me** to on my quest to document all leetcode problems\uD83D\uDE03\nHappy Coding :)\n\n
['C', 'C++']