# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1175976 | elecball | Game (IOI13_game) | C++17 | 0 ms | 0 KiB |
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int R, C, N;
ll gcd(ll a, ll b) {
return b ? gcd(b, a % b) : a;
}
struct updcmd {
int p, q;
ll value;
};
struct qrycmd {
int p, q, u, v;
};
struct Cnode {
int left = -1, right = -1;
ll value;
};
struct Rnode {
vector<Cnode> tree;
int left = -1, right = -1;
Rnode () {
tree.emplace_back();