Simple Backtracking beats 97.80% of C++ online submissions
Consider every skill as the  ith bit set in a binary representation or not. To do so put all the skills n a map with index as their value.\n2. For every person 
1. Consider every skill as the  **ith** bit set in a binary representation or not. To do so put all the skills n a map with index as their value.\n2. For every person find its binary representation of the skill. By **adding (2^i)** if the skill with value i (from the map) is present to them. And store them in vector.\n3. If we include a person then just do **bitwise OR** of his value to total sum.\n4. The desired value to get is (2^n -1) where n is total no of skills required;\n  Eg: if there are only two skills then the bit should be **11** so a value of **3**.\n  \n```\n\tclass Solution {\npublic:\n    vector<int> v;\n    map<string,int> mp;\n    int n; int m;\n    int x;\n    vector<int> pp;\n    \n    void fun(int id,int s,vector<int>& us){\n        if(s >= x){\n            // v.size() < 1 to take where when the vector v is empty then it\'s size is 0\n            if(us.size() < v.size() || v.size() < 1){\n                v = us;\n            }\n            return;\n        }\n        // to limit the no of recursive calls\n        if(id == n ||(v.size()>0 && us.size() >= v.size()))\n            return;\n        \n        int i;\n        // if the ith skill is already included in the current s\n        if(s & (1 << id))\n            fun(id+1,s,us);\n        else{\n            // For every person which has that skill, we wouls try to recurr.\n            for(i=0;i<m;i++){\n                if(pp[i] & (1 << id)){\n                    int p = s | pp[i];\n                    us.push_back(i);\n                    fun(id+1,p,us);\n                    us.pop_back();\n                }\n            }\n        }\n    }\n    vector<int> smallestSufficientTeam(vector<string>& skills, vector<vector<string>>& pep) {\n        n=skills.size();\n        m=pep.size();\n        \n        int i,j;x=1;\n        // storing every skill as key-value pair\n        \n        for(i=0;i<n;i++){\n            mp[skills[i]]=i;\n            x *= 2; \n        }\n        x--; // The desired value when every skill would be included\n       \n        for(i=0;i<m;i++){\n            int y=0;// stores the dcimal representation of every person skills\n            \n            for(j=0;j<pep[i].size();j++){\n                y += (1 << mp[pep[i][j]]);\n            }\n            pp.push_back(y);\n           // cout << y << "\\n";\n        }\n        \n        vector<int> bb;\n        fun(0,0,bb);\n        return v;\n    }\n};\n```
['Backtracking', 'C', 'Bitmask']