Submission #775479

#TimeUsernameProblemLanguageResultExecution timeMemory
775479Trisanu_DasExhibition (JOI19_ho_t2)C++17
0 / 100
1082 ms212 KiB
#include <bits/stdc++.h> using namespace std; int n, m, b[100000]; array<int, 2> a[100000]; int main() { ios::sync_with_stdio(0); cin.tie(0); cin >> n >> m; for(int i = 0; i < n; i++)cin >> a[i][1] >> a[i][0]; for(int i = 0; i < m; i++) cin >> b[i]; sort(a, a + n); sort(b, b + m); int ans = m - 1; for(int i = n - 1; i >= 0; i++) if(ans >= 0 && a[i][1] <= b[ans]) ans--; cout << m - 1 - ans << '\n'; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...