# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
434238 | Kanaifu | Counting Mushrooms (IOI20_mushrooms) | C++14 | 268 ms | 484 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 "mushrooms.h"
//#include "stub.cpp"
using namespace std;
#define pb push_back
int count_mushrooms(int n)
{
bool ident[200001];
ident[0] = false;
vector <int> mush;
mush.pb(0);
for (int i=1; i<n; i++)
{
mush.pb(i);
int numb = use_machine(mush);
ident[i] = numb;
mush.pop_back();
}
int brojac =0;
for (int i=0; i<n; i++)
{
if (ident[i]==0)
{
brojac++;
}
}
return brojac;
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |