# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
434988 | model_code | Fountain Parks (IOI21_parks) | C++17 | 423 ms | 29468 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.
/**
* Task: parks
* Author: Kian Mirjalali
* Solution: Solution based on chessboard coloring of cells (trees)
* Time: O(n*log(n)+n) where n*log(n) is for just 2 sorts
* It computes and keeps the adjacent vertices for each vertex on each direction.
*/
#include "parks.h"
#include <complex>
#include <algorithm>
#include <iostream>
using namespace std;
#define tpc(C) template<class C>
#define allOf(c) ((c).begin()), ((c).end())
#define fori(i, a, b) for (int i = (a); i < int(b); i++)
#define forn(i, n) fori(i, 0, (n))
#define dbg(x) #x << "=" << (x)
#define show(x) cerr << dbg(x) << endl
#define cmpret(a, b) do { if ((a) != (b)) return ((a) < (b)); } while (false)
tpc(C) inline int sz(const C& c) { return c.size(); }
typedef vector<int> VI;
typedef complex<int> Point;
#define X real()
#define Y imag()
# | 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... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |