Submission #926287

#TimeUsernameProblemLanguageResultExecution timeMemory
926287VMaksimoski008Exhibition (JOI19_ho_t2)C++14
100 / 100
115 ms1624 KiB
#include <bits/stdc++.h> using namespace std; int main() { int n, m; cin >> n >> m; vector<array<int, 2> > v(n); vector<int> c(m); for(auto &x : v) cin >> x[1] >> x[0]; for(int &x : c) cin >> x; sort(v.rbegin(), v.rend()); sort(c.rbegin(), c.rend()); int j = 0; for(int i=0; i<n; i++) if(v[i][1] <= c[j]) j++; cout << j << '\n'; return 0; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...