# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
627867 | Fischer | Rarest Insects (IOI22_insects) | C++17 | 59 ms | 336 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 "insects.h"
using namespace std;
const int maxn = 2010;
int in[maxn];
vector<bool> memo;
int n, c;
int base;
vector<int> id;
void put(int x) {
move_inside(x);
//memo[x] = 1;
}
void pop(int x) {
move_outside(x);
//memo[x] = 0;
}
map<vector<bool>, int> mapMemo;
bool last[maxn];
int push() {
return press_button();
if (mapMemo.count(memo)) return mapMemo[memo];
for (int i = 0; i < n; ++i) {
if (last[i] != (in[i] != 0)) {
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |