| # | Time | Username | Problem | Language | Result | Execution time | Memory |
|---|---|---|---|---|---|---|---|
| 1263764 | goulthen | Intercastellar (JOI22_ho_t1) | C++20 | 41 ms | 5444 KiB |
#include <bits/stdc++.h>
using namespace std;
#define int long long
#define rep(i,a,b) for (int i = a; i <= b; ++i)
const int MAXN = 2e5+10;
int a[MAXN],b[MAXN];
int32_t main() {
ios_base::sync_with_stdio(0); cin.tie(nullptr);
int n;cin >> n;
rep(i,1,n) cin >> a[i];
rep(i,1,n) {
b[i] = a[i];
while (b[i]%2==0) b[i] /= 2;
}
int q, j = 1, x = 0;cin >> q;
while (q--) {
int v;cin >> v;
while (j < n && x + a[j]/b[j] < v) {
x+=a[j]/b[j];
j++;
}
cout << b[j] << '\n';
}
}| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
