My issue
what is wrong in this…
My code
#include <bits/stdc++.h>
#include<unordered_map>
#include<algorithm>
#define ll long long int
using namespace std;
int main() {
// your code goes here
int t,n;
cin>>t;
while(t--){
unordered_multimap< ll, ll> mp;
cin>>n;
ll k;
cin>>k;
for(int i=0;i<n;i++){
ll key ,value;
cin>>key>>value;
mp.insert({key,value});
}
ll ans=0;
for(auto pair:mp){
if(pair.first<=k){
ans=max(ans,pair.second);
}
}
cout<<ans<<endl;
}
return 0;
}
Problem Link: CHRL1 Problem - CodeChef