QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#628223#8041. Life is Hard and Undecidable, but...lonelywolf#AC ✓1ms3836kbC++20505b2024-10-10 19:11:472024-10-10 19:11:48

Judging History

你现在查看的是最新测评结果

  • [2024-10-10 19:11:48]
  • 评测
  • 测评结果:AC
  • 用时:1ms
  • 内存:3836kb
  • [2024-10-10 19:11:47]
  • 提交

answer

#include <bits/stdc++.h>  
using namespace std;  

#define int long long  

signed main() {  
    ios::sync_with_stdio(false);
    cin.tie(nullptr);  

	int n;
	cin >> n;

	int x = 1, y = 1;
	vector<pair<int, int>> ans;
	ans.emplace_back(x, y);

	for (int i = 1; i < n; i++) {
		ans.emplace_back(x, y + 2);
		ans.emplace_back(x + 2, y + 2);
		x += 2, y += 2;
	}

	cout << ans.size() << "\n";
	for (auto [x, y] : ans) {
		cout << x << " " << y << "\n";
	}

    return 0;
}  
  

詳細信息

Test #1:

score: 100
Accepted
time: 0ms
memory: 3608kb

input:

1

output:

1
1 1

result:

ok n=1

Test #2:

score: 0
Accepted
time: 0ms
memory: 3556kb

input:

2

output:

3
1 1
1 3
3 3

result:

ok n=3

Test #3:

score: 0
Accepted
time: 0ms
memory: 3836kb

input:

3

output:

5
1 1
1 3
3 3
3 5
5 5

result:

ok n=5

Test #4:

score: 0
Accepted
time: 1ms
memory: 3648kb

input:

4

output:

7
1 1
1 3
3 3
3 5
5 5
5 7
7 7

result:

ok n=7

Test #5:

score: 0
Accepted
time: 1ms
memory: 3608kb

input:

5

output:

9
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9

result:

ok n=9

Test #6:

score: 0
Accepted
time: 1ms
memory: 3808kb

input:

6

output:

11
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11

result:

ok n=11

Test #7:

score: 0
Accepted
time: 0ms
memory: 3608kb

input:

7

output:

13
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13

result:

ok n=13

Test #8:

score: 0
Accepted
time: 1ms
memory: 3608kb

input:

8

output:

15
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13
13 15
15 15

result:

ok n=15

Test #9:

score: 0
Accepted
time: 0ms
memory: 3648kb

input:

9

output:

17
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13
13 15
15 15
15 17
17 17

result:

ok n=17

Test #10:

score: 0
Accepted
time: 1ms
memory: 3808kb

input:

10

output:

19
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13
13 15
15 15
15 17
17 17
17 19
19 19

result:

ok n=19

Test #11:

score: 0
Accepted
time: 1ms
memory: 3804kb

input:

13

output:

25
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13
13 15
15 15
15 17
17 17
17 19
19 19
19 21
21 21
21 23
23 23
23 25
25 25

result:

ok n=25

Test #12:

score: 0
Accepted
time: 1ms
memory: 3552kb

input:

17

output:

33
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13
13 15
15 15
15 17
17 17
17 19
19 19
19 21
21 21
21 23
23 23
23 25
25 25
25 27
27 27
27 29
29 29
29 31
31 31
31 33
33 33

result:

ok n=33

Test #13:

score: 0
Accepted
time: 1ms
memory: 3772kb

input:

23

output:

45
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13
13 15
15 15
15 17
17 17
17 19
19 19
19 21
21 21
21 23
23 23
23 25
25 25
25 27
27 27
27 29
29 29
29 31
31 31
31 33
33 33
33 35
35 35
35 37
37 37
37 39
39 39
39 41
41 41
41 43
43 43
43 45
45 45

result:

ok n=45

Test #14:

score: 0
Accepted
time: 0ms
memory: 3496kb

input:

29

output:

57
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13
13 15
15 15
15 17
17 17
17 19
19 19
19 21
21 21
21 23
23 23
23 25
25 25
25 27
27 27
27 29
29 29
29 31
31 31
31 33
33 33
33 35
35 35
35 37
37 37
37 39
39 39
39 41
41 41
41 43
43 43
43 45
45 45
45 47
47 47
47 49
49 49
49 51
51 51
51 53
53 5...

result:

ok n=57

Test #15:

score: 0
Accepted
time: 0ms
memory: 3808kb

input:

31

output:

61
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13
13 15
15 15
15 17
17 17
17 19
19 19
19 21
21 21
21 23
23 23
23 25
25 25
25 27
27 27
27 29
29 29
29 31
31 31
31 33
33 33
33 35
35 35
35 37
37 37
37 39
39 39
39 41
41 41
41 43
43 43
43 45
45 45
45 47
47 47
47 49
49 49
49 51
51 51
51 53
53 5...

result:

ok n=61

Test #16:

score: 0
Accepted
time: 0ms
memory: 3552kb

input:

37

output:

73
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13
13 15
15 15
15 17
17 17
17 19
19 19
19 21
21 21
21 23
23 23
23 25
25 25
25 27
27 27
27 29
29 29
29 31
31 31
31 33
33 33
33 35
35 35
35 37
37 37
37 39
39 39
39 41
41 41
41 43
43 43
43 45
45 45
45 47
47 47
47 49
49 49
49 51
51 51
51 53
53 5...

result:

ok n=73

Test #17:

score: 0
Accepted
time: 1ms
memory: 3552kb

input:

41

output:

81
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13
13 15
15 15
15 17
17 17
17 19
19 19
19 21
21 21
21 23
23 23
23 25
25 25
25 27
27 27
27 29
29 29
29 31
31 31
31 33
33 33
33 35
35 35
35 37
37 37
37 39
39 39
39 41
41 41
41 43
43 43
43 45
45 45
45 47
47 47
47 49
49 49
49 51
51 51
51 53
53 5...

result:

ok n=81

Test #18:

score: 0
Accepted
time: 1ms
memory: 3560kb

input:

43

output:

85
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13
13 15
15 15
15 17
17 17
17 19
19 19
19 21
21 21
21 23
23 23
23 25
25 25
25 27
27 27
27 29
29 29
29 31
31 31
31 33
33 33
33 35
35 35
35 37
37 37
37 39
39 39
39 41
41 41
41 43
43 43
43 45
45 45
45 47
47 47
47 49
49 49
49 51
51 51
51 53
53 5...

result:

ok n=85

Test #19:

score: 0
Accepted
time: 1ms
memory: 3616kb

input:

100

output:

199
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13
13 15
15 15
15 17
17 17
17 19
19 19
19 21
21 21
21 23
23 23
23 25
25 25
25 27
27 27
27 29
29 29
29 31
31 31
31 33
33 33
33 35
35 35
35 37
37 37
37 39
39 39
39 41
41 41
41 43
43 43
43 45
45 45
45 47
47 47
47 49
49 49
49 51
51 51
51 53
53 ...

result:

ok n=199

Test #20:

score: 0
Accepted
time: 1ms
memory: 3616kb

input:

85

output:

169
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13
13 15
15 15
15 17
17 17
17 19
19 19
19 21
21 21
21 23
23 23
23 25
25 25
25 27
27 27
27 29
29 29
29 31
31 31
31 33
33 33
33 35
35 35
35 37
37 37
37 39
39 39
39 41
41 41
41 43
43 43
43 45
45 45
45 47
47 47
47 49
49 49
49 51
51 51
51 53
53 ...

result:

ok n=169

Test #21:

score: 0
Accepted
time: 1ms
memory: 3548kb

input:

97

output:

193
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13
13 15
15 15
15 17
17 17
17 19
19 19
19 21
21 21
21 23
23 23
23 25
25 25
25 27
27 27
27 29
29 29
29 31
31 31
31 33
33 33
33 35
35 35
35 37
37 37
37 39
39 39
39 41
41 41
41 43
43 43
43 45
45 45
45 47
47 47
47 49
49 49
49 51
51 51
51 53
53 ...

result:

ok n=193

Test #22:

score: 0
Accepted
time: 1ms
memory: 3656kb

input:

98

output:

195
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13
13 15
15 15
15 17
17 17
17 19
19 19
19 21
21 21
21 23
23 23
23 25
25 25
25 27
27 27
27 29
29 29
29 31
31 31
31 33
33 33
33 35
35 35
35 37
37 37
37 39
39 39
39 41
41 41
41 43
43 43
43 45
45 45
45 47
47 47
47 49
49 49
49 51
51 51
51 53
53 ...

result:

ok n=195

Test #23:

score: 0
Accepted
time: 1ms
memory: 3544kb

input:

99

output:

197
1 1
1 3
3 3
3 5
5 5
5 7
7 7
7 9
9 9
9 11
11 11
11 13
13 13
13 15
15 15
15 17
17 17
17 19
19 19
19 21
21 21
21 23
23 23
23 25
25 25
25 27
27 27
27 29
29 29
29 31
31 31
31 33
33 33
33 35
35 35
35 37
37 37
37 39
39 39
39 41
41 41
41 43
43 43
43 45
45 45
45 47
47 47
47 49
49 49
49 51
51 51
51 53
53 ...

result:

ok n=197

Extra Test:

score: 0
Extra Test Passed