C++ (Intuition and STL)
\n//Approach-1 (Intuition)\n/*\n\tmove any character from words[i] to any position in words[j].\n\tThis line above makes things easy. We just need to know if al
```\n//Approach-1 (Intuition)\n/*\n\tmove any character from words[i] to any position in words[j].\n\tThis line above makes things easy. We just need to know if all characters\'\n\tcan be equally distributed to each. i.e.\n\tfrequency[character]%n == 0 for all characters\n*/\n\nclass Solution {\npublic:\n    bool makeEqual(vector<string>& words) {\n        int t[26] = {0};\n        int n = words.size();\n        \n        for(const string& word : words) {\n            for( const char &ch : word) {\n                t[ch-\'a\']++;\n            }\n        }\n        \n        for(const int& x : t) {\n            if(x%n != 0)\n                return false;\n        }\n        return true;\n    }\n};\n```\n\n```\n//Approach-2 (Using STL just for fun)\nclass Solution {\npublic:\n    bool makeEqual(vector<string>& words) {\n        int t[26] = {0};\n        int n = words.size();\n        \n        for(const string& word : words) {\n            for( const char &ch : word) {\n                t[ch-\'a\']++;\n            }\n        }\n        \n        auto lambda = [&n](int &a) {\n            return a%n==0;\n        };\n        \n        return all_of(begin(t), end(t), lambda);\n        \n    }\n};\n```
[]