Compile Error
foo.c:1:10: fatal error: bits/stdc++.h: No such file or directory 1 | #include <bits/stdc++.h> | ^~~~~~~~~~~~~~~ compilation terminated.
Code
#include <bits/stdc++.h>
using namespace std;
#define ll long long
#define endl '\n'
int32_t main()
{
ios_base::sync_with_stdio(0);
cin.tie(0);
int n; cin >> n;
map<int,int>mp;
for (int i = 1; i <= n; i++) {
int x; cin >> x;
mp[x] = i;
}
int q; cin >> q;
while(q--) {
int a; cin >> a;
for (auto [value,indx] : mp) {
int store = indx;
cout << indx << endl;
mp.erase(value);
mp[a] = store;
break;
}
}
return 0;
}
Information
- Submit By
- Type
- Submission
- Problem
- P1086 KuZ the Position
- Contest
- Bangladesh 2.0
- Language
- C99 (GCC 13.2.0)
- Submit At
- 2024-08-16 16:18:23
- Judged At
- 2024-11-11 03:15:13
- Judged By
- Score
- 0
- Total Time
- 0ms
- Peak Memory
- 0 Bytes