# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
674173 | QwertyPi | Cambridge (info1cup18_cambridge) | C++14 | 5 ms | 12756 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>
#define int long long
#define fi first
#define se second
#define pii pair<int, int>
using namespace std;
const int MOD = 1e9 + 7;
const int MAXN = 1e5 + 11;
const int B = 800;
int t[MAXN], d[MAXN];
int ans[MAXN], to[MAXN];
struct query{
int l, r, id;
bool operator< (const query& o) const {
if(l / B != o.l / B)
return l / B < o.l / B;
else if(r != o.r)
return l / B % 2 == 0 ? r < o.r : r > o.r;
else
return id < o.id;
}
};
namespace DS{
struct SegTree{
int mx[MAXN << 3] = {0}, s[MAXN << 3] = {0};
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |