# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
125831 | nvmdava | Exhibition (JOI19_ho_t2) | C++17 | 71 ms | 1656 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
using namespace std;
vector<int> f;
vector<pair<int, int> > v;
int main(){
ios_base::sync_with_stdio(0);
cin.tie(0);
cout.tie(0);
int n, m;
cin>>n>>m;
v.resize(n);
f.resize(m);
for(int i = 0; i < n; i++)
cin>>v[i].second>>v[i].first;
for(int i = 0; i < m; i++)
cin>>f[i];
sort(f.rbegin(), f.rend());
sort(v.rbegin(), v.rend());
int ans = 0;
for(int i = 0; i < n; i++)
if(ans < m && f[ans] >= v[i].second) ans++;
cout<<ans;
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |