SORTNG || SIMPLE || EASY UNDERSTAND C++  SOLUTION
\nclass Solution {\npublic:\n    vector<int> maximumBeauty(vector<vector<int>>& items, vector<int>& queries) {\n       vector<vector<int>> v;\n        int n = q
```\nclass Solution {\npublic:\n    vector<int> maximumBeauty(vector<vector<int>>& items, vector<int>& queries) {\n       vector<vector<int>> v;\n        int n = queries.size();\n        for(int i = 0; i < n; i++){\n            v.push_back({queries[i],i});\n        }\n        sort(v.begin(),v.end());\n        sort(items.begin(),items.end());\n        vector<int> ans(n);\n        int j=0;\n        n = items.size();\n        int mx = 0;\n        for(auto &i: v){\n            while(j<n && items[j][0]<=i[0]){\n                mx = max(mx,items[j][1]);\n                j++;\n            }\n            ans[i[1]] = mx;\n        }\n        return ans;\n    }\n};\n```
['C', 'Sorting', 'C++']