# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1166225 | Hanksburger | Game (IOI13_game) | C++20 | 1995 ms | 299496 KiB |
#include "game.h"
#include <bits/stdc++.h>
#define ll long long
using namespace std;
vector<int> leftchild1, rightchild1, leftchild2, rightchild2;
vector<ll> segtree;
ll large=1e9;
ll createNode()
{
segtree.push_back(0);
leftchild1.push_back(0);
rightchild1.push_back(0);
leftchild2.push_back(0);
rightchild2.push_back(0);
return segtree.size()-1;
}
void update2(ll i, ll l1, ll r1, ll l2, ll r2, ll x, ll y, ll z)
{
if (l2==r2)
{
if (l1==r1)
segtree[i]=z;
else
segtree[i]=gcd(segtree[leftchild1[i]], segtree[rightchild1[i]]);
return;
}
ll mid=(l2+r2)/2;
if (y<=mid)
{
if (!leftchild2[i])
# | 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... |