# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1060574 | Szymon_Pilipczuk | The Xana coup (BOI21_xanadu) | C++17 | 1058 ms | 7792 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 <iostream>
#include <vector>
#include <algorithm>
using namespace std;
int main()
{
int n;
cin>>n;
int o[n];
int ans = n+1;
vector<int> tr[n];
int a,b;
for(int i = 0;i<n-1;i++)
{
cin>>a>>b;
a--;b--;
tr[a].push_back(b);
tr[b].push_back(a);
}
for(int i =0;i<n;i++)
{
cin>>o[i];
}
for(int i = 0;i<(1<<n);i++)
{
int oc[n];
copy(o,o+n,oc);
int ci = i;
int q = 0;
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... |