# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
220224 | atoiz | Ruins 3 (JOI20_ruins3) | C++14 | 494 ms | 8960 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.
/*input
10
5 8 9 13 15 16 17 18 19 20
*/
#include <iostream>
#include <vector>
#include <algorithm>
using namespace std;
#define FOR(i, a, b) for (int i = a; i <= b; ++i)
#define FORB(i, a, b) for (int i = a; i >= b; --i)
const int MAXN = 607, MOD = 1e9 + 7, HALF = (MOD + 1) / 2;
int N, F[MAXN * 2][MAXN], G[2][MAXN][MAXN], H[MAXN], C[MAXN * 2][MAXN * 2];
bool alive[MAXN * 2];
int add(int x, int y)
{ return x -= ((x += y) >= MOD ? MOD : 0); }
int sub(int x, int y)
{ return x += ((x -= y) < 0 ? MOD : 0); }
int mul(int x, int y)
{ return int(1ll * x * y % MOD); }
int main()
{
ios_base::sync_with_stdio(0); cin.tie(0);
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |