Codeforces Round #436 (Div. 2), problem: (F) Cities Excursions Solution In C/C++

By | 2017-09-26T16:42:50+00:00 September 26th, 2017|Categories: C/C++, Programming|Tags: , , , , , , , |

#include<cstdio> #include<algorithm> #include<cstring> using namespace std; const int N = 3005, INF = 0x3f3f3f3f; int n, m, q, f[N][12]; bool vis[N]; struct Edge { int to; Edge *next; Edge () {} Edge (int to, Edge *next) : to(to), next(next) {} }*head[N], pool[N << 1], [...]