Submission #1014951

# Submission time Handle Problem Language Result Execution time Memory
1014951 2024-07-05T19:11:43 Z rainboy Tiles (BOI24_tiles) C
100 / 100
170 ms 23480 KB
#include <stdio.h>
#include <string.h>

#define N	200000
#define N_	(1 << 18)	/* N_ = pow2(ceil(log2(N))) */

int max(int a, int b) { return a > b ? a : b; }

unsigned int Z = 12345;

int rand_() {
	return (Z *= 3) >> 1;
}

int xx[N], yy[N], n;

int compare_y(int i, int j) {
	return yy[i] - yy[j];
}

int compare_xy(int i, int j) {
	return xx[i] != xx[j] ? xx[i] - xx[j] : yy[i] - yy[j];
}

int (*compare)(int, int);

void sort(int *ii, int l, int r) {
	while (l < r) {
		int i = l, j = l, k = r, i_ = ii[l + rand_() % (r - l)], tmp;

		while (j < k) {
			int c = compare(ii[j], i_);

			if (c == 0)
				j++;
			else if (c < 0) {
				tmp = ii[i], ii[i] = ii[j], ii[j] = tmp;
				i++, j++;
			} else {
				k--;
				tmp = ii[j], ii[j] = ii[k], ii[k] = tmp;
			}
		}
		sort(ii, l, i);
		l = k;
	}
}

int yy1[N], n1;

int sz[N_ * 2];
int ss1[N_ * 2], ss2[N_ * 2];
int ccp[N_ * 2], ssp[N_ * 2];
int ccq[N_ * 2], ssq[N_ * 2];
char good[N_ * 2]; char lz[N_];
int h_, n_;

int flip(int c) {
	return c == 0 ? 0 : (c < 0 ? (c == -1 ? -2 : -1) : (c == 1 ? 2 : 1));
}

void put(int i, int x) {
	int tmp;

	if (x == -1) {
		tmp = ss1[i], ss1[i] = ss2[i], ss2[i] = tmp;
		ccp[i] = flip(ccp[i]), ccq[i] = flip(ccq[i]);
		if (i < n_)
			lz[i] = flip(lz[i]);
	} else if (x != -2) {
		if (x == 0)
			ss1[i] = ss2[i] = 0;
		else if (x == 1)
			ss1[i] = sz[i], ss2[i] = 0;
		else
			ss1[i] = 0, ss2[i] = sz[i];
		ccp[i] = ccq[i] = x, ssp[i] = ssq[i] = x == 0 ? 0 : sz[i];
		good[i] = 1;
		if (i < n_)
			lz[i] = x;
	}
}

void pus(int i) {
	if (lz[i] != -2)
		put(i << 1 | 0, lz[i]), put(i << 1 | 1, lz[i]), lz[i] = -2;
}

void pul(int i) {
	if (lz[i] == -2) {
		int l = i << 1, r = l | 1;

		ss1[i] = ss1[l] + ss1[r], ss2[i] = ss2[l] + ss2[r];
		ccp[i] = ccp[l];
		if (ccp[l] == 0)
			ssp[i] = 0;
		else
			ssp[i] = ssp[l] < sz[l] || ccp[r] != ccp[l] ? ssp[l] : sz[l] + ssp[r];
		ccq[i] = ccq[r];
		if (ccq[r] == 0)
			ssq[i] = 0;
		else
			ssq[i] = ssq[r] < sz[r] || ccq[l] != ccq[r] ? ssq[r] : ssq[l] + sz[r];
		good[i] = good[l] && good[r] && (ccq[l] != ccp[r] ? (ssq[l] == sz[l] || ssq[l] % 2 == 0) && (ssp[r] == sz[r] || ssp[r] % 2 == 0) : ssq[l] == sz[l] || ssp[r] == sz[r] || (ssq[l] + ssp[r]) % 2 == 0);
	}
}

void push(int i) {
	int h;

	for (h = h_; h > 0; h--)
		pus(i >> h);
}

void pull(int i) {
	while (i > 1)
		pul(i >>= 1);
}

void build() {
	int i;

	h_ = 0;
	while (1 << h_ < n1)
		h_++;
	n_ = 1 << h_;
	memset(lz, -2, n_ * sizeof *lz);
	memset(good, 1, n_ * 2 * sizeof *good);
	for (i = 0; i < n1; i++)
		sz[n_ + i] = i + 1 < n1 ? yy1[i + 1] - yy1[i] : 1;
	for (i = n_ - 1; i > 0; i--)
		sz[i] = sz[i << 1 | 0] + sz[i << 1 | 1], pul(i);
}

void update(int l, int r, int x) {
	int l_ = l += n_, r_ = r += n_;

	push(l_), push(r_);
	for ( ; l <= r; l >>= 1, r >>= 1) {
		if ((l & 1) == 1)
			put(l++, x);
		if ((r & 1) == 0)
			put(r--, x);
	}
	pull(l_), pull(r_);
}

int query(int l, int r) {
	int s, s1, s2;

	push(l += n_), push(r += n_);
	s = 0, s1 = s2 = 0;
	for ( ; l <= r; l >>= 1, r >>= 1) {
		if ((l & 1) == 1)
			s += sz[l], s1 += ss1[l], s2 += ss2[l], l++;
		if ((r & 1) == 0)
			s += sz[r], s1 += ss1[r], s2 += ss2[r], r--;
	}
	return s1 == 0 && s2 == 0 ? 1 : (s1 == s ? 0 : -1);
}

int main() {
	static int ii[N], xx_[N], yy_[N];
	int i, j, x1, x2, y, y1, y2, ans, t;

	scanf("%d%*d", &n);
	for (i = 0; i < n; i++)
		scanf("%d%d", &xx[i], &yy[i]);
	n1 = 0;
	for (i = 0; i < n; i++)
		if ((xx[i] != xx[(i + 1) % n]) != (xx[i] != xx[(i - 1 + n) % n]))
			xx_[n1] = xx[i], yy_[n1] = yy[i], n1++;
	memcpy(xx, xx_, n1 * sizeof *xx_), memcpy(yy, yy_, n1 * sizeof *yy_), n = n1;
	for (i = 0; i < n; i++)
		ii[i] = i;
	compare = compare_y, sort(ii, 0, n);
	n1 = 0;
	for (i = 0; i < n; i = j) {
		j = i, y = yy[ii[i]];
		while (j < n && yy[ii[j]] == y)
			yy[ii[j++]] = n1;
		yy1[n1++] = y;
	}
	build();
	compare = compare_xy, sort(ii, 0, n);
	ans = 0;
	for (i = 0; i + 1 < n; i += 2) {
		y1 = yy[ii[i]], y2 = yy[ii[i + 1]];
		t = query(y1, y2 - 1);
		if (t == -1)
			break;
		update(y1, y2 - 1, t);
		if (i + 2 < n && xx[ii[i + 2]] != xx[ii[i + 1]]) {
			if (!good[1] || ssp[1] % 2 != 0 || ssq[1] % 2 != 0)
				break;
			x1 = xx[ii[i + 1]], x2 = xx[ii[i + 2]];
			if (ss2[1] == 0)
				ans = max(ans, x1 + (x2 - x1) / 2 * 2);
			if (ss1[1] == 0)
				ans = max(ans, x1 + 1 + (x2 - x1 - 1) / 2 * 2);
			if ((x2 - x1) % 2 != 0)
				put(1, -1);
		}
	}
	printf("%d\n", ans);
	return 0;
}

Compilation message

Main.c: In function 'main':
Main.c:166:2: warning: ignoring return value of 'scanf' declared with attribute 'warn_unused_result' [-Wunused-result]
  166 |  scanf("%d%*d", &n);
      |  ^~~~~~~~~~~~~~~~~~
Main.c:168:3: warning: ignoring return value of 'scanf' declared with attribute 'warn_unused_result' [-Wunused-result]
  168 |   scanf("%d%d", &xx[i], &yy[i]);
      |   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Verdict Execution time Memory Grader output
1 Correct 1 ms 10584 KB Output is correct
2 Correct 1 ms 10584 KB Output is correct
3 Correct 1 ms 10588 KB Output is correct
4 Correct 1 ms 10588 KB Output is correct
5 Correct 1 ms 10588 KB Output is correct
6 Correct 1 ms 10584 KB Output is correct
7 Correct 1 ms 10588 KB Output is correct
8 Correct 1 ms 10588 KB Output is correct
9 Correct 1 ms 10588 KB Output is correct
10 Correct 1 ms 10588 KB Output is correct
11 Correct 1 ms 10588 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 10584 KB Output is correct
2 Correct 1 ms 10584 KB Output is correct
3 Correct 1 ms 10588 KB Output is correct
4 Correct 1 ms 10588 KB Output is correct
5 Correct 1 ms 10588 KB Output is correct
6 Correct 1 ms 10584 KB Output is correct
7 Correct 1 ms 10588 KB Output is correct
8 Correct 1 ms 10588 KB Output is correct
9 Correct 1 ms 10588 KB Output is correct
10 Correct 1 ms 10588 KB Output is correct
11 Correct 1 ms 10588 KB Output is correct
12 Correct 1 ms 10588 KB Output is correct
13 Correct 1 ms 10588 KB Output is correct
14 Correct 1 ms 10588 KB Output is correct
15 Correct 1 ms 10588 KB Output is correct
16 Correct 1 ms 10588 KB Output is correct
17 Correct 1 ms 10588 KB Output is correct
18 Correct 1 ms 10588 KB Output is correct
19 Correct 1 ms 10588 KB Output is correct
20 Correct 1 ms 10588 KB Output is correct
21 Correct 1 ms 10708 KB Output is correct
22 Correct 1 ms 10588 KB Output is correct
23 Correct 1 ms 10588 KB Output is correct
24 Correct 2 ms 10588 KB Output is correct
25 Correct 1 ms 10588 KB Output is correct
26 Correct 1 ms 10588 KB Output is correct
27 Correct 1 ms 10588 KB Output is correct
28 Correct 1 ms 10588 KB Output is correct
29 Correct 2 ms 10588 KB Output is correct
30 Correct 1 ms 10588 KB Output is correct
31 Correct 2 ms 10588 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 10588 KB Output is correct
2 Correct 11 ms 11436 KB Output is correct
3 Correct 103 ms 14932 KB Output is correct
4 Correct 81 ms 19368 KB Output is correct
5 Correct 52 ms 19292 KB Output is correct
6 Correct 1 ms 10584 KB Output is correct
7 Correct 1 ms 10588 KB Output is correct
8 Correct 84 ms 14240 KB Output is correct
9 Correct 68 ms 19328 KB Output is correct
10 Correct 62 ms 13652 KB Output is correct
11 Correct 69 ms 19408 KB Output is correct
12 Correct 1 ms 10584 KB Output is correct
13 Correct 125 ms 15704 KB Output is correct
14 Correct 1 ms 10584 KB Output is correct
15 Correct 1 ms 10588 KB Output is correct
16 Correct 1 ms 10588 KB Output is correct
17 Correct 1 ms 10588 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 10588 KB Output is correct
2 Correct 1 ms 10588 KB Output is correct
3 Correct 1 ms 10656 KB Output is correct
4 Correct 1 ms 10588 KB Output is correct
5 Correct 64 ms 10912 KB Output is correct
6 Correct 74 ms 11092 KB Output is correct
7 Correct 1 ms 10588 KB Output is correct
8 Correct 1 ms 10588 KB Output is correct
9 Correct 1 ms 10588 KB Output is correct
10 Correct 2 ms 10588 KB Output is correct
11 Correct 1 ms 10588 KB Output is correct
12 Correct 1 ms 10588 KB Output is correct
13 Correct 1 ms 10588 KB Output is correct
14 Correct 1 ms 10588 KB Output is correct
15 Correct 1 ms 10588 KB Output is correct
16 Correct 1 ms 10588 KB Output is correct
17 Correct 78 ms 10900 KB Output is correct
18 Correct 71 ms 10936 KB Output is correct
19 Correct 2 ms 10588 KB Output is correct
20 Correct 1 ms 10588 KB Output is correct
21 Correct 1 ms 10588 KB Output is correct
22 Correct 1 ms 10588 KB Output is correct
23 Correct 1 ms 10588 KB Output is correct
24 Correct 1 ms 10588 KB Output is correct
25 Correct 1 ms 10584 KB Output is correct
26 Correct 1 ms 10588 KB Output is correct
27 Correct 1 ms 10588 KB Output is correct
28 Correct 1 ms 10588 KB Output is correct
29 Correct 1 ms 10588 KB Output is correct
30 Correct 1 ms 10588 KB Output is correct
31 Correct 1 ms 10588 KB Output is correct
32 Correct 1 ms 10588 KB Output is correct
33 Correct 1 ms 10588 KB Output is correct
34 Correct 1 ms 10588 KB Output is correct
35 Correct 1 ms 10588 KB Output is correct
36 Correct 1 ms 10588 KB Output is correct
37 Correct 1 ms 10588 KB Output is correct
38 Correct 1 ms 10588 KB Output is correct
39 Correct 1 ms 10584 KB Output is correct
40 Correct 1 ms 10588 KB Output is correct
41 Correct 1 ms 10588 KB Output is correct
42 Correct 1 ms 10588 KB Output is correct
43 Correct 1 ms 10588 KB Output is correct
44 Correct 1 ms 10588 KB Output is correct
45 Correct 1 ms 10588 KB Output is correct
46 Correct 1 ms 10588 KB Output is correct
47 Correct 1 ms 10588 KB Output is correct
48 Correct 1 ms 10640 KB Output is correct
49 Correct 85 ms 10920 KB Output is correct
50 Correct 77 ms 10920 KB Output is correct
51 Correct 85 ms 10880 KB Output is correct
52 Correct 82 ms 10928 KB Output is correct
53 Correct 1 ms 10588 KB Output is correct
54 Correct 1 ms 10588 KB Output is correct
55 Correct 2 ms 10588 KB Output is correct
56 Correct 2 ms 10588 KB Output is correct
57 Correct 2 ms 10724 KB Output is correct
58 Correct 1 ms 10588 KB Output is correct
59 Correct 1 ms 10584 KB Output is correct
60 Correct 1 ms 10588 KB Output is correct
61 Correct 1 ms 10588 KB Output is correct
62 Correct 1 ms 10676 KB Output is correct
63 Correct 2 ms 10588 KB Output is correct
64 Correct 2 ms 10588 KB Output is correct
65 Correct 1 ms 10588 KB Output is correct
66 Correct 1 ms 10588 KB Output is correct
67 Correct 1 ms 10588 KB Output is correct
68 Correct 1 ms 10588 KB Output is correct
69 Correct 1 ms 10588 KB Output is correct
70 Correct 1 ms 10588 KB Output is correct
71 Correct 2 ms 10588 KB Output is correct
72 Correct 1 ms 10584 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 10584 KB Output is correct
2 Correct 59 ms 19344 KB Output is correct
3 Correct 50 ms 19280 KB Output is correct
4 Correct 50 ms 10844 KB Output is correct
5 Correct 74 ms 10832 KB Output is correct
6 Correct 2 ms 10588 KB Output is correct
7 Correct 2 ms 10584 KB Output is correct
8 Correct 64 ms 10832 KB Output is correct
9 Correct 66 ms 11008 KB Output is correct
10 Correct 97 ms 11008 KB Output is correct
11 Correct 101 ms 10908 KB Output is correct
12 Correct 111 ms 15188 KB Output is correct
13 Correct 106 ms 15264 KB Output is correct
14 Correct 65 ms 13908 KB Output is correct
15 Correct 69 ms 10840 KB Output is correct
16 Correct 136 ms 15264 KB Output is correct
17 Correct 98 ms 14860 KB Output is correct
18 Correct 137 ms 23440 KB Output is correct
19 Correct 94 ms 14928 KB Output is correct
20 Correct 80 ms 14868 KB Output is correct
21 Correct 74 ms 14472 KB Output is correct
22 Correct 93 ms 14900 KB Output is correct
23 Correct 98 ms 18684 KB Output is correct
24 Correct 118 ms 18720 KB Output is correct
25 Correct 131 ms 18580 KB Output is correct
26 Correct 134 ms 17492 KB Output is correct
27 Correct 109 ms 17636 KB Output is correct
28 Correct 121 ms 18260 KB Output is correct
29 Correct 83 ms 14672 KB Output is correct
30 Correct 100 ms 14960 KB Output is correct
31 Correct 75 ms 14416 KB Output is correct
32 Correct 112 ms 14748 KB Output is correct
33 Correct 61 ms 17416 KB Output is correct
34 Correct 52 ms 21008 KB Output is correct
35 Correct 1 ms 10588 KB Output is correct
36 Correct 1 ms 10588 KB Output is correct
37 Correct 1 ms 10584 KB Output is correct
38 Correct 1 ms 10588 KB Output is correct
39 Correct 1 ms 10588 KB Output is correct
40 Correct 1 ms 10588 KB Output is correct
41 Correct 1 ms 10664 KB Output is correct
42 Correct 1 ms 10588 KB Output is correct
43 Correct 1 ms 10588 KB Output is correct
44 Correct 1 ms 10588 KB Output is correct
45 Correct 1 ms 10588 KB Output is correct
46 Correct 1 ms 10588 KB Output is correct
47 Correct 1 ms 10588 KB Output is correct
48 Correct 1 ms 10588 KB Output is correct
49 Correct 151 ms 23428 KB Output is correct
50 Correct 1 ms 10588 KB Output is correct
51 Correct 1 ms 10588 KB Output is correct
52 Correct 122 ms 21832 KB Output is correct
53 Correct 79 ms 12472 KB Output is correct
54 Correct 88 ms 12368 KB Output is correct
55 Correct 82 ms 12440 KB Output is correct
56 Correct 75 ms 12456 KB Output is correct
57 Correct 1 ms 10584 KB Output is correct
58 Correct 1 ms 10664 KB Output is correct
59 Correct 1 ms 10588 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 97 ms 14756 KB Output is correct
2 Correct 62 ms 21332 KB Output is correct
3 Correct 2 ms 10588 KB Output is correct
4 Correct 71 ms 17552 KB Output is correct
5 Correct 1 ms 10584 KB Output is correct
6 Correct 91 ms 14740 KB Output is correct
7 Correct 2 ms 10844 KB Output is correct
8 Correct 106 ms 23440 KB Output is correct
9 Correct 100 ms 14744 KB Output is correct
10 Correct 84 ms 17804 KB Output is correct
11 Correct 60 ms 17748 KB Output is correct
12 Correct 74 ms 18000 KB Output is correct
13 Correct 100 ms 14672 KB Output is correct
14 Correct 96 ms 14676 KB Output is correct
15 Correct 103 ms 14672 KB Output is correct
16 Correct 111 ms 18728 KB Output is correct
17 Correct 113 ms 18512 KB Output is correct
18 Correct 107 ms 18512 KB Output is correct
19 Correct 62 ms 21328 KB Output is correct
20 Correct 1 ms 10584 KB Output is correct
21 Correct 84 ms 18200 KB Output is correct
22 Correct 66 ms 21588 KB Output is correct
23 Correct 1 ms 10588 KB Output is correct
24 Correct 2 ms 10588 KB Output is correct
25 Correct 1 ms 10588 KB Output is correct
26 Correct 1 ms 10584 KB Output is correct
27 Correct 1 ms 10588 KB Output is correct
28 Correct 1 ms 10588 KB Output is correct
29 Correct 1 ms 10588 KB Output is correct
30 Correct 1 ms 10588 KB Output is correct
31 Correct 1 ms 10588 KB Output is correct
32 Correct 1 ms 10668 KB Output is correct
33 Correct 1 ms 10588 KB Output is correct
34 Correct 1 ms 10588 KB Output is correct
35 Correct 1 ms 10588 KB Output is correct
36 Correct 62 ms 21300 KB Output is correct
37 Correct 82 ms 12372 KB Output is correct
38 Correct 82 ms 12372 KB Output is correct
39 Correct 75 ms 12368 KB Output is correct
40 Correct 79 ms 12408 KB Output is correct
41 Correct 1 ms 10584 KB Output is correct
42 Correct 1 ms 10588 KB Output is correct
43 Correct 1 ms 10588 KB Output is correct
44 Correct 1 ms 10588 KB Output is correct
45 Correct 1 ms 10588 KB Output is correct
46 Correct 2 ms 10588 KB Output is correct
# Verdict Execution time Memory Grader output
1 Correct 1 ms 10584 KB Output is correct
2 Correct 1 ms 10584 KB Output is correct
3 Correct 1 ms 10588 KB Output is correct
4 Correct 1 ms 10588 KB Output is correct
5 Correct 1 ms 10588 KB Output is correct
6 Correct 1 ms 10584 KB Output is correct
7 Correct 1 ms 10588 KB Output is correct
8 Correct 1 ms 10588 KB Output is correct
9 Correct 1 ms 10588 KB Output is correct
10 Correct 1 ms 10588 KB Output is correct
11 Correct 1 ms 10588 KB Output is correct
12 Correct 1 ms 10588 KB Output is correct
13 Correct 1 ms 10588 KB Output is correct
14 Correct 1 ms 10588 KB Output is correct
15 Correct 1 ms 10588 KB Output is correct
16 Correct 1 ms 10588 KB Output is correct
17 Correct 1 ms 10588 KB Output is correct
18 Correct 1 ms 10588 KB Output is correct
19 Correct 1 ms 10588 KB Output is correct
20 Correct 1 ms 10588 KB Output is correct
21 Correct 1 ms 10708 KB Output is correct
22 Correct 1 ms 10588 KB Output is correct
23 Correct 1 ms 10588 KB Output is correct
24 Correct 2 ms 10588 KB Output is correct
25 Correct 1 ms 10588 KB Output is correct
26 Correct 1 ms 10588 KB Output is correct
27 Correct 1 ms 10588 KB Output is correct
28 Correct 1 ms 10588 KB Output is correct
29 Correct 2 ms 10588 KB Output is correct
30 Correct 1 ms 10588 KB Output is correct
31 Correct 2 ms 10588 KB Output is correct
32 Correct 1 ms 10588 KB Output is correct
33 Correct 11 ms 11436 KB Output is correct
34 Correct 103 ms 14932 KB Output is correct
35 Correct 81 ms 19368 KB Output is correct
36 Correct 52 ms 19292 KB Output is correct
37 Correct 1 ms 10584 KB Output is correct
38 Correct 1 ms 10588 KB Output is correct
39 Correct 84 ms 14240 KB Output is correct
40 Correct 68 ms 19328 KB Output is correct
41 Correct 62 ms 13652 KB Output is correct
42 Correct 69 ms 19408 KB Output is correct
43 Correct 1 ms 10584 KB Output is correct
44 Correct 125 ms 15704 KB Output is correct
45 Correct 1 ms 10584 KB Output is correct
46 Correct 1 ms 10588 KB Output is correct
47 Correct 1 ms 10588 KB Output is correct
48 Correct 1 ms 10588 KB Output is correct
49 Correct 1 ms 10588 KB Output is correct
50 Correct 1 ms 10588 KB Output is correct
51 Correct 1 ms 10656 KB Output is correct
52 Correct 1 ms 10588 KB Output is correct
53 Correct 64 ms 10912 KB Output is correct
54 Correct 74 ms 11092 KB Output is correct
55 Correct 1 ms 10588 KB Output is correct
56 Correct 1 ms 10588 KB Output is correct
57 Correct 1 ms 10588 KB Output is correct
58 Correct 2 ms 10588 KB Output is correct
59 Correct 1 ms 10588 KB Output is correct
60 Correct 1 ms 10588 KB Output is correct
61 Correct 1 ms 10588 KB Output is correct
62 Correct 1 ms 10588 KB Output is correct
63 Correct 1 ms 10588 KB Output is correct
64 Correct 1 ms 10588 KB Output is correct
65 Correct 78 ms 10900 KB Output is correct
66 Correct 71 ms 10936 KB Output is correct
67 Correct 2 ms 10588 KB Output is correct
68 Correct 1 ms 10588 KB Output is correct
69 Correct 1 ms 10588 KB Output is correct
70 Correct 1 ms 10588 KB Output is correct
71 Correct 1 ms 10588 KB Output is correct
72 Correct 1 ms 10588 KB Output is correct
73 Correct 1 ms 10584 KB Output is correct
74 Correct 1 ms 10588 KB Output is correct
75 Correct 1 ms 10588 KB Output is correct
76 Correct 1 ms 10588 KB Output is correct
77 Correct 1 ms 10588 KB Output is correct
78 Correct 1 ms 10588 KB Output is correct
79 Correct 1 ms 10588 KB Output is correct
80 Correct 1 ms 10588 KB Output is correct
81 Correct 1 ms 10588 KB Output is correct
82 Correct 1 ms 10588 KB Output is correct
83 Correct 1 ms 10588 KB Output is correct
84 Correct 1 ms 10588 KB Output is correct
85 Correct 1 ms 10588 KB Output is correct
86 Correct 1 ms 10588 KB Output is correct
87 Correct 1 ms 10584 KB Output is correct
88 Correct 1 ms 10588 KB Output is correct
89 Correct 1 ms 10588 KB Output is correct
90 Correct 1 ms 10588 KB Output is correct
91 Correct 1 ms 10588 KB Output is correct
92 Correct 1 ms 10588 KB Output is correct
93 Correct 1 ms 10588 KB Output is correct
94 Correct 1 ms 10588 KB Output is correct
95 Correct 1 ms 10588 KB Output is correct
96 Correct 1 ms 10640 KB Output is correct
97 Correct 85 ms 10920 KB Output is correct
98 Correct 77 ms 10920 KB Output is correct
99 Correct 85 ms 10880 KB Output is correct
100 Correct 82 ms 10928 KB Output is correct
101 Correct 1 ms 10588 KB Output is correct
102 Correct 1 ms 10588 KB Output is correct
103 Correct 2 ms 10588 KB Output is correct
104 Correct 2 ms 10588 KB Output is correct
105 Correct 2 ms 10724 KB Output is correct
106 Correct 1 ms 10588 KB Output is correct
107 Correct 1 ms 10584 KB Output is correct
108 Correct 1 ms 10588 KB Output is correct
109 Correct 1 ms 10588 KB Output is correct
110 Correct 1 ms 10676 KB Output is correct
111 Correct 2 ms 10588 KB Output is correct
112 Correct 2 ms 10588 KB Output is correct
113 Correct 1 ms 10588 KB Output is correct
114 Correct 1 ms 10588 KB Output is correct
115 Correct 1 ms 10588 KB Output is correct
116 Correct 1 ms 10588 KB Output is correct
117 Correct 1 ms 10588 KB Output is correct
118 Correct 1 ms 10588 KB Output is correct
119 Correct 2 ms 10588 KB Output is correct
120 Correct 1 ms 10584 KB Output is correct
121 Correct 1 ms 10584 KB Output is correct
122 Correct 59 ms 19344 KB Output is correct
123 Correct 50 ms 19280 KB Output is correct
124 Correct 50 ms 10844 KB Output is correct
125 Correct 74 ms 10832 KB Output is correct
126 Correct 2 ms 10588 KB Output is correct
127 Correct 2 ms 10584 KB Output is correct
128 Correct 64 ms 10832 KB Output is correct
129 Correct 66 ms 11008 KB Output is correct
130 Correct 97 ms 11008 KB Output is correct
131 Correct 101 ms 10908 KB Output is correct
132 Correct 111 ms 15188 KB Output is correct
133 Correct 106 ms 15264 KB Output is correct
134 Correct 65 ms 13908 KB Output is correct
135 Correct 69 ms 10840 KB Output is correct
136 Correct 136 ms 15264 KB Output is correct
137 Correct 98 ms 14860 KB Output is correct
138 Correct 137 ms 23440 KB Output is correct
139 Correct 94 ms 14928 KB Output is correct
140 Correct 80 ms 14868 KB Output is correct
141 Correct 74 ms 14472 KB Output is correct
142 Correct 93 ms 14900 KB Output is correct
143 Correct 98 ms 18684 KB Output is correct
144 Correct 118 ms 18720 KB Output is correct
145 Correct 131 ms 18580 KB Output is correct
146 Correct 134 ms 17492 KB Output is correct
147 Correct 109 ms 17636 KB Output is correct
148 Correct 121 ms 18260 KB Output is correct
149 Correct 83 ms 14672 KB Output is correct
150 Correct 100 ms 14960 KB Output is correct
151 Correct 75 ms 14416 KB Output is correct
152 Correct 112 ms 14748 KB Output is correct
153 Correct 61 ms 17416 KB Output is correct
154 Correct 52 ms 21008 KB Output is correct
155 Correct 1 ms 10588 KB Output is correct
156 Correct 1 ms 10588 KB Output is correct
157 Correct 1 ms 10584 KB Output is correct
158 Correct 1 ms 10588 KB Output is correct
159 Correct 1 ms 10588 KB Output is correct
160 Correct 1 ms 10588 KB Output is correct
161 Correct 1 ms 10664 KB Output is correct
162 Correct 1 ms 10588 KB Output is correct
163 Correct 1 ms 10588 KB Output is correct
164 Correct 1 ms 10588 KB Output is correct
165 Correct 1 ms 10588 KB Output is correct
166 Correct 1 ms 10588 KB Output is correct
167 Correct 1 ms 10588 KB Output is correct
168 Correct 1 ms 10588 KB Output is correct
169 Correct 151 ms 23428 KB Output is correct
170 Correct 1 ms 10588 KB Output is correct
171 Correct 1 ms 10588 KB Output is correct
172 Correct 122 ms 21832 KB Output is correct
173 Correct 79 ms 12472 KB Output is correct
174 Correct 88 ms 12368 KB Output is correct
175 Correct 82 ms 12440 KB Output is correct
176 Correct 75 ms 12456 KB Output is correct
177 Correct 1 ms 10584 KB Output is correct
178 Correct 1 ms 10664 KB Output is correct
179 Correct 1 ms 10588 KB Output is correct
180 Correct 97 ms 14756 KB Output is correct
181 Correct 62 ms 21332 KB Output is correct
182 Correct 2 ms 10588 KB Output is correct
183 Correct 71 ms 17552 KB Output is correct
184 Correct 1 ms 10584 KB Output is correct
185 Correct 91 ms 14740 KB Output is correct
186 Correct 2 ms 10844 KB Output is correct
187 Correct 106 ms 23440 KB Output is correct
188 Correct 100 ms 14744 KB Output is correct
189 Correct 84 ms 17804 KB Output is correct
190 Correct 60 ms 17748 KB Output is correct
191 Correct 74 ms 18000 KB Output is correct
192 Correct 100 ms 14672 KB Output is correct
193 Correct 96 ms 14676 KB Output is correct
194 Correct 103 ms 14672 KB Output is correct
195 Correct 111 ms 18728 KB Output is correct
196 Correct 113 ms 18512 KB Output is correct
197 Correct 107 ms 18512 KB Output is correct
198 Correct 62 ms 21328 KB Output is correct
199 Correct 1 ms 10584 KB Output is correct
200 Correct 84 ms 18200 KB Output is correct
201 Correct 66 ms 21588 KB Output is correct
202 Correct 1 ms 10588 KB Output is correct
203 Correct 2 ms 10588 KB Output is correct
204 Correct 1 ms 10588 KB Output is correct
205 Correct 1 ms 10584 KB Output is correct
206 Correct 1 ms 10588 KB Output is correct
207 Correct 1 ms 10588 KB Output is correct
208 Correct 1 ms 10588 KB Output is correct
209 Correct 1 ms 10588 KB Output is correct
210 Correct 1 ms 10588 KB Output is correct
211 Correct 1 ms 10668 KB Output is correct
212 Correct 1 ms 10588 KB Output is correct
213 Correct 1 ms 10588 KB Output is correct
214 Correct 1 ms 10588 KB Output is correct
215 Correct 62 ms 21300 KB Output is correct
216 Correct 82 ms 12372 KB Output is correct
217 Correct 82 ms 12372 KB Output is correct
218 Correct 75 ms 12368 KB Output is correct
219 Correct 79 ms 12408 KB Output is correct
220 Correct 1 ms 10584 KB Output is correct
221 Correct 1 ms 10588 KB Output is correct
222 Correct 1 ms 10588 KB Output is correct
223 Correct 1 ms 10588 KB Output is correct
224 Correct 1 ms 10588 KB Output is correct
225 Correct 2 ms 10588 KB Output is correct
226 Correct 103 ms 14932 KB Output is correct
227 Correct 59 ms 17492 KB Output is correct
228 Correct 170 ms 19028 KB Output is correct
229 Correct 79 ms 14416 KB Output is correct
230 Correct 159 ms 23480 KB Output is correct
231 Correct 108 ms 18512 KB Output is correct
232 Correct 95 ms 14420 KB Output is correct
233 Correct 72 ms 21312 KB Output is correct
234 Correct 123 ms 18960 KB Output is correct
235 Correct 108 ms 19072 KB Output is correct
236 Correct 146 ms 18504 KB Output is correct
237 Correct 148 ms 18696 KB Output is correct
238 Correct 56 ms 21680 KB Output is correct
239 Correct 147 ms 23380 KB Output is correct
240 Correct 170 ms 19216 KB Output is correct
241 Correct 112 ms 19024 KB Output is correct
242 Correct 32 ms 21072 KB Output is correct