# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
448914 | JovanB | Pipes (BOI13_pipes) | C++17 | 264 ms | 23980 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>
using namespace std;
using ll = long long;
using ld = long double;
const int N = 100000;
const int M = 500000;
ll cap[N+5];
vector <pair <int, int>> graf[N+5];
int deg[N+5];
bool bio[N+5];
ll sol[M+5];
pair <int, int> f[N+5][2];
void idi(int v, int lst, int root){
if(v == root && lst != 0) return;
int was = 0;
for(auto pr : graf[v]){
int c = pr.first;
if(deg[c] <= 0) continue;
if(v == root){
f[v][was++] = pr;
}
else{
if(c == lst) f[v][0] = pr;
else f[v][1] = pr;
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |