# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
645638 | abeker | Game (IOI13_game) | C++17 | 3851 ms | 256000 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>
#include "game.h"
using namespace std;
typedef long long ll;
const int offset = 1 << 30;
const int MAX_ROW = 1e6;
const int MAX_COL = 1.8e7;
int row_root;
int root[MAX_ROW], l[MAX_ROW], r[MAX_ROW];
unsigned char left_child[3 * MAX_COL], right_child[3 * MAX_COL];
ll num[MAX_COL];
ll gcd(ll a, ll b) {
return b ? gcd(b, a % b) : a;
}
void create_col(int &node) {
static int sz;
if (!node)
node = ++sz;
}
void create_row(int &node) {
static int sz;
if (!node) {
node = ++sz;
create_col(root[node]);
# | 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... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |