Simple and easy solutions, beats 90% ✅✅
\n\n# Code\n\nclass Solution {\npublic:\n    vector<int> intersection(vector<vector<int>>& nums) {\n        map<int,int> m; // use mao because we need result in
\n\n# Code\n```\nclass Solution {\npublic:\n    vector<int> intersection(vector<vector<int>>& nums) {\n        map<int,int> m; // use mao because we need result in sorted order\n\n        // keep count of each element\n        for(int i = 0 ; i < nums.size(); i++){\n            for(int &x : nums[i]){\n                m[x]++;\n            }\n        }\n\n        vector<int> ans;\n\n        // if frequency of element == size of vector, means it is present in all\n        for(auto &x : m){\n            if(x.second == nums.size()){\n                ans.push_back(x.first);\n            }\n        }\n\n        return ans;\n    }\n};\n```
['C++']