# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
610997 | Ozy | Dungeons Game (IOI21_dungeons) | C++17 | 165 ms | 40688 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 "dungeons.h"
#include <bits/stdc++.h>
using namespace std;
#define lli long long int
#define rep(i,a,b) for (int i = (a); i <= (b); i++)
#define repa(i,a,b) for (int i = (a); i >= (b); i--)
#define MAX 400000
#define anc first
#define sum second
lli N,fuerza;
pair<lli,lli> st[MAX+2][32];
vector<lli> hijos[MAX+2];
lli camino[MAX+2];
void dfs(lli pos, lli padre, lli prof) {
camino[pos] = prof*fuerza;
for (auto h : hijos[pos]) {
if (h == padre) continue;
dfs(h,pos,prof+1);
}
}
void init(int n, std::vector<int> s, std::vector<int> p, std::vector<int> w, std::vector<int> l) {
N = n;
fuerza = s[0];
rep(i, 0, n-1) st[i][0] = {l[i],p[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... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |