# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1082333 | Cyanberry | Dungeons Game (IOI21_dungeons) | C++17 | 7087 ms | 26676 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;
vector<int> strL, pity, winR, lossR;
void init(int n, std::vector<int> s, std::vector<int> p, std::vector<int> w, std::vector<int> l) {
strL = s;
pity = p;
winR = w;
lossR = l;
return;
}
long long simulate(int loc, int strIn) {
long long str = strIn;
while (loc != strL.size()) {
if (str >= strL[loc]) {
str += strL[loc];
loc = winR[loc];
} else {
str += pity[loc];
loc = lossR[loc];
}
}
return str;
}
Compilation message (stderr)
# | 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... |