답안 #25330

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
25330 2017-06-21T07:36:13 Z RezwanArefin01 Aliens (IOI16_aliens) C++14
25 / 100
2000 ms 23888 KB
#include "aliens.h"
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;

struct seg {
	ll l, r; 
	bool operator < (const seg &p) const {
		return l == p.l ? r > p.r : l < p.l;
	}
};
#define sq(a) ((a) * (a))
ll take_photos(int n, int m, int kk, std::vector<int> r, std::vector<int> c) { 
	vector<seg> tmp, v;
	for(int i=0; i<n; i++) {
		if(r[i] > c[i]) 
			swap(r[i], c[i]);
		tmp.push_back({r[i], c[i]});
	} sort(tmp.begin(), tmp.end());

	for(int i=0; i<n; i++) {
		if(v.size() && v.back().l <= tmp[i].l && tmp[i].r <= v.back().r) continue;
		v.push_back(tmp[i]); 
	}
	n = v.size(); 
	ll dp[kk+1][n+1];
	memset(dp, 0x3f, sizeof dp); 
	for(int i=1; i<=n; i++) {
		dp[1][i] = sq(v[i-1].r - v[0].l + 1);
	} 
	for(int k=2; k<=kk; k++) {
		for(int i=1; i<=n; i++) {
			for(int j=0; j<i; j++) {
				ll len = sq(v[i-1].r - v[j].l + 1);
				if(j && v[j].l <= v[j-1].r) 
					len -= sq(v[j-1].r - v[j].l+ 1);
				dp[k][i] = min(dp[k][i], dp[k-1][j] + len);
			}
		}
	} 
	ll Min = 1e18;
	for(int k=1; k <= kk; k++) Min = min(Min, dp[k][n]); 
    return Min;
}
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 2024 KB Correct answer: answer = 4
2 Correct 0 ms 2024 KB Correct answer: answer = 4
3 Correct 0 ms 2024 KB Correct answer: answer = 4
4 Correct 0 ms 2024 KB Correct answer: answer = 12
5 Correct 0 ms 2024 KB Correct answer: answer = 52
6 Correct 0 ms 2024 KB Correct answer: answer = 210
7 Correct 0 ms 2024 KB Correct answer: answer = 88
8 Correct 0 ms 2024 KB Correct answer: answer = 7696
9 Correct 0 ms 2024 KB Correct answer: answer = 1
10 Correct 0 ms 2024 KB Correct answer: answer = 2374
11 Correct 0 ms 2024 KB Correct answer: answer = 9502
12 Correct 0 ms 2024 KB Correct answer: answer = 49
13 Correct 0 ms 2024 KB Correct answer: answer = 151
14 Correct 0 ms 2024 KB Correct answer: answer = 7550
15 Correct 0 ms 2024 KB Correct answer: answer = 7220
16 Correct 0 ms 2024 KB Correct answer: answer = 7550
17 Correct 0 ms 2024 KB Correct answer: answer = 10000
18 Correct 0 ms 2024 KB Correct answer: answer = 10000
19 Correct 0 ms 2024 KB Correct answer: answer = 624
20 Correct 0 ms 2024 KB Correct answer: answer = 10000
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 2024 KB Correct answer: answer = 1
2 Correct 0 ms 2024 KB Correct answer: answer = 4
3 Correct 0 ms 2024 KB Correct answer: answer = 1
4 Correct 0 ms 2024 KB Correct answer: answer = 5
5 Correct 0 ms 2024 KB Correct answer: answer = 41
6 Correct 0 ms 2024 KB Correct answer: answer = 71923
7 Correct 0 ms 2024 KB Correct answer: answer = 77137
8 Correct 39 ms 2672 KB Correct answer: answer = 764
9 Correct 0 ms 2024 KB Correct answer: answer = 250000
10 Correct 126 ms 3856 KB Correct answer: answer = 500
11 Correct 0 ms 2024 KB Correct answer: answer = 32
12 Correct 0 ms 2024 KB Correct answer: answer = 130050
13 Correct 9 ms 2092 KB Correct answer: answer = 5110
14 Correct 0 ms 2024 KB Correct answer: answer = 2626
15 Correct 6 ms 2068 KB Correct answer: answer = 796
16 Correct 6 ms 2036 KB Correct answer: answer = 7580
17 Correct 29 ms 2420 KB Correct answer: answer = 1904
18 Correct 0 ms 2024 KB Correct answer: answer = 996004
19 Correct 3 ms 2024 KB Correct answer: answer = 38817
20 Correct 13 ms 2204 KB Correct answer: answer = 4096
21 Correct 0 ms 2024 KB Correct answer: answer = 1
22 Correct 0 ms 2024 KB Correct answer: answer = 1
23 Correct 29 ms 2384 KB Correct answer: answer = 2040
24 Correct 0 ms 2024 KB Correct answer: answer = 2
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 2024 KB Correct answer: answer = 4
2 Correct 0 ms 2024 KB Correct answer: answer = 4
3 Correct 0 ms 2024 KB Correct answer: answer = 4
4 Correct 0 ms 2024 KB Correct answer: answer = 12
5 Correct 0 ms 2024 KB Correct answer: answer = 52
6 Correct 0 ms 2024 KB Correct answer: answer = 210
7 Correct 0 ms 2024 KB Correct answer: answer = 88
8 Correct 0 ms 2024 KB Correct answer: answer = 7696
9 Correct 0 ms 2024 KB Correct answer: answer = 1
10 Correct 0 ms 2024 KB Correct answer: answer = 2374
11 Correct 0 ms 2024 KB Correct answer: answer = 9502
12 Correct 0 ms 2024 KB Correct answer: answer = 49
13 Correct 0 ms 2024 KB Correct answer: answer = 151
14 Correct 0 ms 2024 KB Correct answer: answer = 7550
15 Correct 0 ms 2024 KB Correct answer: answer = 7220
16 Correct 0 ms 2024 KB Correct answer: answer = 7550
17 Correct 0 ms 2024 KB Correct answer: answer = 10000
18 Correct 0 ms 2024 KB Correct answer: answer = 10000
19 Correct 0 ms 2024 KB Correct answer: answer = 624
20 Correct 0 ms 2024 KB Correct answer: answer = 10000
21 Correct 0 ms 2024 KB Correct answer: answer = 1
22 Correct 0 ms 2024 KB Correct answer: answer = 4
23 Correct 0 ms 2024 KB Correct answer: answer = 1
24 Correct 0 ms 2024 KB Correct answer: answer = 5
25 Correct 0 ms 2024 KB Correct answer: answer = 41
26 Correct 0 ms 2024 KB Correct answer: answer = 71923
27 Correct 0 ms 2024 KB Correct answer: answer = 77137
28 Correct 39 ms 2672 KB Correct answer: answer = 764
29 Correct 0 ms 2024 KB Correct answer: answer = 250000
30 Correct 126 ms 3856 KB Correct answer: answer = 500
31 Correct 0 ms 2024 KB Correct answer: answer = 32
32 Correct 0 ms 2024 KB Correct answer: answer = 130050
33 Correct 9 ms 2092 KB Correct answer: answer = 5110
34 Correct 0 ms 2024 KB Correct answer: answer = 2626
35 Correct 6 ms 2068 KB Correct answer: answer = 796
36 Correct 6 ms 2036 KB Correct answer: answer = 7580
37 Correct 29 ms 2420 KB Correct answer: answer = 1904
38 Correct 0 ms 2024 KB Correct answer: answer = 996004
39 Correct 3 ms 2024 KB Correct answer: answer = 38817
40 Correct 13 ms 2204 KB Correct answer: answer = 4096
41 Correct 0 ms 2024 KB Correct answer: answer = 1
42 Correct 0 ms 2024 KB Correct answer: answer = 1
43 Correct 29 ms 2384 KB Correct answer: answer = 2040
44 Correct 0 ms 2024 KB Correct answer: answer = 2
45 Correct 0 ms 2024 KB Correct answer: answer = 4
46 Correct 0 ms 2024 KB Correct answer: answer = 9
47 Correct 0 ms 2024 KB Correct answer: answer = 9
48 Correct 0 ms 2024 KB Correct answer: answer = 21
49 Correct 0 ms 2024 KB Correct answer: answer = 71
50 Correct 0 ms 2024 KB Correct answer: answer = 77
51 Correct 0 ms 2024 KB Correct answer: answer = 400
52 Correct 0 ms 2024 KB Correct answer: answer = 996004
53 Correct 0 ms 2024 KB Correct answer: answer = 997310
54 Correct 0 ms 2024 KB Correct answer: answer = 990781
55 Correct 0 ms 2024 KB Correct answer: answer = 996545
56 Correct 0 ms 2024 KB Correct answer: answer = 484
57 Correct 0 ms 2024 KB Correct answer: answer = 484
58 Correct 0 ms 2024 KB Correct answer: answer = 63501
59 Correct 6 ms 2024 KB Correct answer: answer = 323501
60 Correct 29 ms 2296 KB Correct answer: answer = 752500
61 Correct 3 ms 2024 KB Correct answer: answer = 761480
62 Correct 13 ms 2284 KB Correct answer: answer = 758932
63 Correct 0 ms 2024 KB Correct answer: answer = 1000000
64 Correct 189 ms 3860 KB Correct answer: answer = 750500
65 Correct 0 ms 2024 KB Correct answer: answer = 1000000
66 Correct 0 ms 2024 KB Correct answer: answer = 250000
67 Correct 0 ms 2024 KB Correct answer: answer = 250000
68 Correct 0 ms 2024 KB Correct answer: answer = 1000000
69 Correct 0 ms 2024 KB Correct answer: answer = 994009
70 Correct 0 ms 2024 KB Correct answer: answer = 59315
71 Correct 3 ms 2032 KB Correct answer: answer = 25454
72 Correct 16 ms 2256 KB Correct answer: answer = 1504
73 Correct 0 ms 2024 KB Correct answer: answer = 37486
74 Correct 6 ms 2108 KB Correct answer: answer = 4284
75 Correct 0 ms 2044 KB Correct answer: answer = 158008
76 Correct 0 ms 2024 KB Correct answer: answer = 51860
77 Correct 0 ms 2024 KB Correct answer: answer = 12985
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 2024 KB Correct answer: answer = 4
2 Correct 0 ms 2024 KB Correct answer: answer = 4
3 Correct 0 ms 2024 KB Correct answer: answer = 4
4 Correct 0 ms 2024 KB Correct answer: answer = 12
5 Correct 0 ms 2024 KB Correct answer: answer = 52
6 Correct 0 ms 2024 KB Correct answer: answer = 210
7 Correct 0 ms 2024 KB Correct answer: answer = 88
8 Correct 0 ms 2024 KB Correct answer: answer = 7696
9 Correct 0 ms 2024 KB Correct answer: answer = 1
10 Correct 0 ms 2024 KB Correct answer: answer = 2374
11 Correct 0 ms 2024 KB Correct answer: answer = 9502
12 Correct 0 ms 2024 KB Correct answer: answer = 49
13 Correct 0 ms 2024 KB Correct answer: answer = 151
14 Correct 0 ms 2024 KB Correct answer: answer = 7550
15 Correct 0 ms 2024 KB Correct answer: answer = 7220
16 Correct 0 ms 2024 KB Correct answer: answer = 7550
17 Correct 0 ms 2024 KB Correct answer: answer = 10000
18 Correct 0 ms 2024 KB Correct answer: answer = 10000
19 Correct 0 ms 2024 KB Correct answer: answer = 624
20 Correct 0 ms 2024 KB Correct answer: answer = 10000
21 Correct 0 ms 2024 KB Correct answer: answer = 1
22 Correct 0 ms 2024 KB Correct answer: answer = 4
23 Correct 0 ms 2024 KB Correct answer: answer = 1
24 Correct 0 ms 2024 KB Correct answer: answer = 5
25 Correct 0 ms 2024 KB Correct answer: answer = 41
26 Correct 0 ms 2024 KB Correct answer: answer = 71923
27 Correct 0 ms 2024 KB Correct answer: answer = 77137
28 Correct 39 ms 2672 KB Correct answer: answer = 764
29 Correct 0 ms 2024 KB Correct answer: answer = 250000
30 Correct 126 ms 3856 KB Correct answer: answer = 500
31 Correct 0 ms 2024 KB Correct answer: answer = 32
32 Correct 0 ms 2024 KB Correct answer: answer = 130050
33 Correct 9 ms 2092 KB Correct answer: answer = 5110
34 Correct 0 ms 2024 KB Correct answer: answer = 2626
35 Correct 6 ms 2068 KB Correct answer: answer = 796
36 Correct 6 ms 2036 KB Correct answer: answer = 7580
37 Correct 29 ms 2420 KB Correct answer: answer = 1904
38 Correct 0 ms 2024 KB Correct answer: answer = 996004
39 Correct 3 ms 2024 KB Correct answer: answer = 38817
40 Correct 13 ms 2204 KB Correct answer: answer = 4096
41 Correct 0 ms 2024 KB Correct answer: answer = 1
42 Correct 0 ms 2024 KB Correct answer: answer = 1
43 Correct 29 ms 2384 KB Correct answer: answer = 2040
44 Correct 0 ms 2024 KB Correct answer: answer = 2
45 Correct 0 ms 2024 KB Correct answer: answer = 4
46 Correct 0 ms 2024 KB Correct answer: answer = 9
47 Correct 0 ms 2024 KB Correct answer: answer = 9
48 Correct 0 ms 2024 KB Correct answer: answer = 21
49 Correct 0 ms 2024 KB Correct answer: answer = 71
50 Correct 0 ms 2024 KB Correct answer: answer = 77
51 Correct 0 ms 2024 KB Correct answer: answer = 400
52 Correct 0 ms 2024 KB Correct answer: answer = 996004
53 Correct 0 ms 2024 KB Correct answer: answer = 997310
54 Correct 0 ms 2024 KB Correct answer: answer = 990781
55 Correct 0 ms 2024 KB Correct answer: answer = 996545
56 Correct 0 ms 2024 KB Correct answer: answer = 484
57 Correct 0 ms 2024 KB Correct answer: answer = 484
58 Correct 0 ms 2024 KB Correct answer: answer = 63501
59 Correct 6 ms 2024 KB Correct answer: answer = 323501
60 Correct 29 ms 2296 KB Correct answer: answer = 752500
61 Correct 3 ms 2024 KB Correct answer: answer = 761480
62 Correct 13 ms 2284 KB Correct answer: answer = 758932
63 Correct 0 ms 2024 KB Correct answer: answer = 1000000
64 Correct 189 ms 3860 KB Correct answer: answer = 750500
65 Correct 0 ms 2024 KB Correct answer: answer = 1000000
66 Correct 0 ms 2024 KB Correct answer: answer = 250000
67 Correct 0 ms 2024 KB Correct answer: answer = 250000
68 Correct 0 ms 2024 KB Correct answer: answer = 1000000
69 Correct 0 ms 2024 KB Correct answer: answer = 994009
70 Correct 0 ms 2024 KB Correct answer: answer = 59315
71 Correct 3 ms 2032 KB Correct answer: answer = 25454
72 Correct 16 ms 2256 KB Correct answer: answer = 1504
73 Correct 0 ms 2024 KB Correct answer: answer = 37486
74 Correct 6 ms 2108 KB Correct answer: answer = 4284
75 Correct 0 ms 2044 KB Correct answer: answer = 158008
76 Correct 0 ms 2024 KB Correct answer: answer = 51860
77 Correct 0 ms 2024 KB Correct answer: answer = 12985
78 Correct 3 ms 2164 KB Correct answer: answer = 997864126212
79 Correct 0 ms 2164 KB Correct answer: answer = 998608411647
80 Correct 3 ms 2388 KB Correct answer: answer = 995265560477
81 Correct 16 ms 2356 KB Correct answer: answer = 10125000
82 Correct 93 ms 2480 KB Correct answer: answer = 2291668
83 Correct 416 ms 3640 KB Correct answer: answer = 42388
84 Correct 1643 ms 8572 KB Correct answer: answer = 10318
85 Execution timed out 2000 ms 23888 KB Execution timed out
86 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 2024 KB Correct answer: answer = 4
2 Correct 0 ms 2024 KB Correct answer: answer = 4
3 Correct 0 ms 2024 KB Correct answer: answer = 4
4 Correct 0 ms 2024 KB Correct answer: answer = 12
5 Correct 0 ms 2024 KB Correct answer: answer = 52
6 Correct 0 ms 2024 KB Correct answer: answer = 210
7 Correct 0 ms 2024 KB Correct answer: answer = 88
8 Correct 0 ms 2024 KB Correct answer: answer = 7696
9 Correct 0 ms 2024 KB Correct answer: answer = 1
10 Correct 0 ms 2024 KB Correct answer: answer = 2374
11 Correct 0 ms 2024 KB Correct answer: answer = 9502
12 Correct 0 ms 2024 KB Correct answer: answer = 49
13 Correct 0 ms 2024 KB Correct answer: answer = 151
14 Correct 0 ms 2024 KB Correct answer: answer = 7550
15 Correct 0 ms 2024 KB Correct answer: answer = 7220
16 Correct 0 ms 2024 KB Correct answer: answer = 7550
17 Correct 0 ms 2024 KB Correct answer: answer = 10000
18 Correct 0 ms 2024 KB Correct answer: answer = 10000
19 Correct 0 ms 2024 KB Correct answer: answer = 624
20 Correct 0 ms 2024 KB Correct answer: answer = 10000
21 Correct 0 ms 2024 KB Correct answer: answer = 1
22 Correct 0 ms 2024 KB Correct answer: answer = 4
23 Correct 0 ms 2024 KB Correct answer: answer = 1
24 Correct 0 ms 2024 KB Correct answer: answer = 5
25 Correct 0 ms 2024 KB Correct answer: answer = 41
26 Correct 0 ms 2024 KB Correct answer: answer = 71923
27 Correct 0 ms 2024 KB Correct answer: answer = 77137
28 Correct 39 ms 2672 KB Correct answer: answer = 764
29 Correct 0 ms 2024 KB Correct answer: answer = 250000
30 Correct 126 ms 3856 KB Correct answer: answer = 500
31 Correct 0 ms 2024 KB Correct answer: answer = 32
32 Correct 0 ms 2024 KB Correct answer: answer = 130050
33 Correct 9 ms 2092 KB Correct answer: answer = 5110
34 Correct 0 ms 2024 KB Correct answer: answer = 2626
35 Correct 6 ms 2068 KB Correct answer: answer = 796
36 Correct 6 ms 2036 KB Correct answer: answer = 7580
37 Correct 29 ms 2420 KB Correct answer: answer = 1904
38 Correct 0 ms 2024 KB Correct answer: answer = 996004
39 Correct 3 ms 2024 KB Correct answer: answer = 38817
40 Correct 13 ms 2204 KB Correct answer: answer = 4096
41 Correct 0 ms 2024 KB Correct answer: answer = 1
42 Correct 0 ms 2024 KB Correct answer: answer = 1
43 Correct 29 ms 2384 KB Correct answer: answer = 2040
44 Correct 0 ms 2024 KB Correct answer: answer = 2
45 Correct 0 ms 2024 KB Correct answer: answer = 4
46 Correct 0 ms 2024 KB Correct answer: answer = 9
47 Correct 0 ms 2024 KB Correct answer: answer = 9
48 Correct 0 ms 2024 KB Correct answer: answer = 21
49 Correct 0 ms 2024 KB Correct answer: answer = 71
50 Correct 0 ms 2024 KB Correct answer: answer = 77
51 Correct 0 ms 2024 KB Correct answer: answer = 400
52 Correct 0 ms 2024 KB Correct answer: answer = 996004
53 Correct 0 ms 2024 KB Correct answer: answer = 997310
54 Correct 0 ms 2024 KB Correct answer: answer = 990781
55 Correct 0 ms 2024 KB Correct answer: answer = 996545
56 Correct 0 ms 2024 KB Correct answer: answer = 484
57 Correct 0 ms 2024 KB Correct answer: answer = 484
58 Correct 0 ms 2024 KB Correct answer: answer = 63501
59 Correct 6 ms 2024 KB Correct answer: answer = 323501
60 Correct 29 ms 2296 KB Correct answer: answer = 752500
61 Correct 3 ms 2024 KB Correct answer: answer = 761480
62 Correct 13 ms 2284 KB Correct answer: answer = 758932
63 Correct 0 ms 2024 KB Correct answer: answer = 1000000
64 Correct 189 ms 3860 KB Correct answer: answer = 750500
65 Correct 0 ms 2024 KB Correct answer: answer = 1000000
66 Correct 0 ms 2024 KB Correct answer: answer = 250000
67 Correct 0 ms 2024 KB Correct answer: answer = 250000
68 Correct 0 ms 2024 KB Correct answer: answer = 1000000
69 Correct 0 ms 2024 KB Correct answer: answer = 994009
70 Correct 0 ms 2024 KB Correct answer: answer = 59315
71 Correct 3 ms 2032 KB Correct answer: answer = 25454
72 Correct 16 ms 2256 KB Correct answer: answer = 1504
73 Correct 0 ms 2024 KB Correct answer: answer = 37486
74 Correct 6 ms 2108 KB Correct answer: answer = 4284
75 Correct 0 ms 2044 KB Correct answer: answer = 158008
76 Correct 0 ms 2024 KB Correct answer: answer = 51860
77 Correct 0 ms 2024 KB Correct answer: answer = 12985
78 Correct 3 ms 2164 KB Correct answer: answer = 997864126212
79 Correct 0 ms 2164 KB Correct answer: answer = 998608411647
80 Correct 3 ms 2388 KB Correct answer: answer = 995265560477
81 Correct 16 ms 2356 KB Correct answer: answer = 10125000
82 Correct 93 ms 2480 KB Correct answer: answer = 2291668
83 Correct 416 ms 3640 KB Correct answer: answer = 42388
84 Correct 1643 ms 8572 KB Correct answer: answer = 10318
85 Execution timed out 2000 ms 23888 KB Execution timed out
86 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 2024 KB Correct answer: answer = 4
2 Correct 0 ms 2024 KB Correct answer: answer = 4
3 Correct 0 ms 2024 KB Correct answer: answer = 4
4 Correct 0 ms 2024 KB Correct answer: answer = 12
5 Correct 0 ms 2024 KB Correct answer: answer = 52
6 Correct 0 ms 2024 KB Correct answer: answer = 210
7 Correct 0 ms 2024 KB Correct answer: answer = 88
8 Correct 0 ms 2024 KB Correct answer: answer = 7696
9 Correct 0 ms 2024 KB Correct answer: answer = 1
10 Correct 0 ms 2024 KB Correct answer: answer = 2374
11 Correct 0 ms 2024 KB Correct answer: answer = 9502
12 Correct 0 ms 2024 KB Correct answer: answer = 49
13 Correct 0 ms 2024 KB Correct answer: answer = 151
14 Correct 0 ms 2024 KB Correct answer: answer = 7550
15 Correct 0 ms 2024 KB Correct answer: answer = 7220
16 Correct 0 ms 2024 KB Correct answer: answer = 7550
17 Correct 0 ms 2024 KB Correct answer: answer = 10000
18 Correct 0 ms 2024 KB Correct answer: answer = 10000
19 Correct 0 ms 2024 KB Correct answer: answer = 624
20 Correct 0 ms 2024 KB Correct answer: answer = 10000
21 Correct 0 ms 2024 KB Correct answer: answer = 1
22 Correct 0 ms 2024 KB Correct answer: answer = 4
23 Correct 0 ms 2024 KB Correct answer: answer = 1
24 Correct 0 ms 2024 KB Correct answer: answer = 5
25 Correct 0 ms 2024 KB Correct answer: answer = 41
26 Correct 0 ms 2024 KB Correct answer: answer = 71923
27 Correct 0 ms 2024 KB Correct answer: answer = 77137
28 Correct 39 ms 2672 KB Correct answer: answer = 764
29 Correct 0 ms 2024 KB Correct answer: answer = 250000
30 Correct 126 ms 3856 KB Correct answer: answer = 500
31 Correct 0 ms 2024 KB Correct answer: answer = 32
32 Correct 0 ms 2024 KB Correct answer: answer = 130050
33 Correct 9 ms 2092 KB Correct answer: answer = 5110
34 Correct 0 ms 2024 KB Correct answer: answer = 2626
35 Correct 6 ms 2068 KB Correct answer: answer = 796
36 Correct 6 ms 2036 KB Correct answer: answer = 7580
37 Correct 29 ms 2420 KB Correct answer: answer = 1904
38 Correct 0 ms 2024 KB Correct answer: answer = 996004
39 Correct 3 ms 2024 KB Correct answer: answer = 38817
40 Correct 13 ms 2204 KB Correct answer: answer = 4096
41 Correct 0 ms 2024 KB Correct answer: answer = 1
42 Correct 0 ms 2024 KB Correct answer: answer = 1
43 Correct 29 ms 2384 KB Correct answer: answer = 2040
44 Correct 0 ms 2024 KB Correct answer: answer = 2
45 Correct 0 ms 2024 KB Correct answer: answer = 4
46 Correct 0 ms 2024 KB Correct answer: answer = 9
47 Correct 0 ms 2024 KB Correct answer: answer = 9
48 Correct 0 ms 2024 KB Correct answer: answer = 21
49 Correct 0 ms 2024 KB Correct answer: answer = 71
50 Correct 0 ms 2024 KB Correct answer: answer = 77
51 Correct 0 ms 2024 KB Correct answer: answer = 400
52 Correct 0 ms 2024 KB Correct answer: answer = 996004
53 Correct 0 ms 2024 KB Correct answer: answer = 997310
54 Correct 0 ms 2024 KB Correct answer: answer = 990781
55 Correct 0 ms 2024 KB Correct answer: answer = 996545
56 Correct 0 ms 2024 KB Correct answer: answer = 484
57 Correct 0 ms 2024 KB Correct answer: answer = 484
58 Correct 0 ms 2024 KB Correct answer: answer = 63501
59 Correct 6 ms 2024 KB Correct answer: answer = 323501
60 Correct 29 ms 2296 KB Correct answer: answer = 752500
61 Correct 3 ms 2024 KB Correct answer: answer = 761480
62 Correct 13 ms 2284 KB Correct answer: answer = 758932
63 Correct 0 ms 2024 KB Correct answer: answer = 1000000
64 Correct 189 ms 3860 KB Correct answer: answer = 750500
65 Correct 0 ms 2024 KB Correct answer: answer = 1000000
66 Correct 0 ms 2024 KB Correct answer: answer = 250000
67 Correct 0 ms 2024 KB Correct answer: answer = 250000
68 Correct 0 ms 2024 KB Correct answer: answer = 1000000
69 Correct 0 ms 2024 KB Correct answer: answer = 994009
70 Correct 0 ms 2024 KB Correct answer: answer = 59315
71 Correct 3 ms 2032 KB Correct answer: answer = 25454
72 Correct 16 ms 2256 KB Correct answer: answer = 1504
73 Correct 0 ms 2024 KB Correct answer: answer = 37486
74 Correct 6 ms 2108 KB Correct answer: answer = 4284
75 Correct 0 ms 2044 KB Correct answer: answer = 158008
76 Correct 0 ms 2024 KB Correct answer: answer = 51860
77 Correct 0 ms 2024 KB Correct answer: answer = 12985
78 Correct 3 ms 2164 KB Correct answer: answer = 997864126212
79 Correct 0 ms 2164 KB Correct answer: answer = 998608411647
80 Correct 3 ms 2388 KB Correct answer: answer = 995265560477
81 Correct 16 ms 2356 KB Correct answer: answer = 10125000
82 Correct 93 ms 2480 KB Correct answer: answer = 2291668
83 Correct 416 ms 3640 KB Correct answer: answer = 42388
84 Correct 1643 ms 8572 KB Correct answer: answer = 10318
85 Execution timed out 2000 ms 23888 KB Execution timed out
86 Halted 0 ms 0 KB -