QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#100127#6319. Parallel Processing (Easy)tikhon#AC ✓2ms3552kbC++172.9kb2023-04-24 19:02:132023-04-24 19:02:15

Judging History

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

  • [2023-08-10 23:21:45]
  • System Update: QOJ starts to keep a history of the judgings of all the submissions.
  • [2023-04-24 19:02:15]
  • 评测
  • 测评结果:AC
  • 用时:2ms
  • 内存:3552kb
  • [2023-04-24 19:02:13]
  • 提交

answer

#include<bits/stdc++.h>

using namespace std;
#define ll long long
#define pii pair<int, int>
#define ld long double
#define all(a) (a).begin(), (a).end()

signed main() {
    ios_base::sync_with_stdio(0);
    cin.tie(0);
    cout.tie(0);

    int n;
    cin >> n;

    if (n <= 2) {
        cout << "1\n"\
                "2 1 2\n"\
                "3 3 3\n"\
                "3 3 3\n"\
                "3 3 3\n";
    } else if (n <= 4) {
        cout << "2\n"\
                "2 1 2\n"\
                "4 3 4\n"\
                "5 5 5\n"\
                "5 5 5\n"\
                "3 2 3\n"\
                "4 2 4\n"\
                "5 5 5\n"\
                "5 5 5\n";
    } else if (n <= 8) {
        cout << "3\n"\
                "2 1 2\n"\
                "4 3 4\n"\
                "6 5 6\n"\
                "8 7 8\n"\

                "4 2 4\n"\
                "8 6 8\n"\
                "7 6 7\n"\
                "3 2 3\n"\
                
                "8 4 8\n"\
                "7 4 7\n"\
                "6 4 6\n"\
                "5 4 5\n";
    } else if (n <= 11) {
        cout << "4\n"\
                "2 1 2\n"\
                "4 3 4\n"\
                "6 5 6\n"\
                "8 7 8\n"\

                "4 2 4\n"\
                "8 6 8\n"\
                "3 2 3\n"\
                "10 9 10\n"\

                "5 4 5\n"\
                "6 4 6\n"\
                "11 10 11\n"\
                "8 4 8\n"\

                "7 6 7\n"\
                "9 8 9\n"\
                "10 8 10\n"\
                "11 8 11\n";            
    } else if (n <= 13) {
        cout << "5\n"\
                "2 1 2\n"\
                "4 3 4\n"\
                "6 5 6\n"\
                "8 7 8\n"\

                "4 2 4\n"\
                "8 6 8\n"\
                "10 9 10\n"\
                "12 11 12\n"\

                "8 4 8\n"\
                "12 10 12\n"\
                "5 4 5\n"\
                "3 2 3\n"\

                "9 8 9\n"\
                "10 8 10\n"\
                "12 8 12\n"\
                "6 4 6\n"\

                "11 10 11\n"\
                "13 12 13\n"\
                "7 6 7\n"\
                "20 20 20\n";
    } else if (n <= 16) {
        cout << "6\n"\
                "2 1 2\n"\
                "4 3 4\n"\
                "6 5 6\n"\
                "8 7 8\n"\

                "4 2 4\n"\
                "8 6 8\n"\
                "10 9 10\n"\
                "12 11 12\n"\

                "8 4 8\n"\
                "5 4 5\n"\
                "6 4 6\n"\
                "12 10 12\n"\

                "9 8 9\n"\
                "7 6 7\n"\
                "14 13 14\n"\
                "12 8 12\n"\

                "10 8 10\n"\
                "16 15 16\n"\
                "13 12 13\n"\
                "14 12 14\n"\

                "11 10 11\n"\
                "3 2 3\n"\
                "15 14 15\n"\
                "16 14 16\n";
    }

    return 0;
}

詳細信息

Test #1:

score: 100
Accepted
time: 1ms
memory: 3436kb

input:

2

output:

1
2 1 2
3 3 3
3 3 3
3 3 3

result:

ok AC

Test #2:

score: 0
Accepted
time: 2ms
memory: 3436kb

input:

4

output:

2
2 1 2
4 3 4
5 5 5
5 5 5
3 2 3
4 2 4
5 5 5
5 5 5

result:

ok AC

Test #3:

score: 0
Accepted
time: 2ms
memory: 3448kb

input:

3

output:

2
2 1 2
4 3 4
5 5 5
5 5 5
3 2 3
4 2 4
5 5 5
5 5 5

result:

ok AC

Test #4:

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

input:

5

output:

3
2 1 2
4 3 4
6 5 6
8 7 8
4 2 4
8 6 8
7 6 7
3 2 3
8 4 8
7 4 7
6 4 6
5 4 5

result:

ok AC

Test #5:

score: 0
Accepted
time: 2ms
memory: 3368kb

input:

6

output:

3
2 1 2
4 3 4
6 5 6
8 7 8
4 2 4
8 6 8
7 6 7
3 2 3
8 4 8
7 4 7
6 4 6
5 4 5

result:

ok AC

Test #6:

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

input:

7

output:

3
2 1 2
4 3 4
6 5 6
8 7 8
4 2 4
8 6 8
7 6 7
3 2 3
8 4 8
7 4 7
6 4 6
5 4 5

result:

ok AC

Test #7:

score: 0
Accepted
time: 2ms
memory: 3368kb

input:

8

output:

3
2 1 2
4 3 4
6 5 6
8 7 8
4 2 4
8 6 8
7 6 7
3 2 3
8 4 8
7 4 7
6 4 6
5 4 5

result:

ok AC

Test #8:

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

input:

9

output:

4
2 1 2
4 3 4
6 5 6
8 7 8
4 2 4
8 6 8
3 2 3
10 9 10
5 4 5
6 4 6
11 10 11
8 4 8
7 6 7
9 8 9
10 8 10
11 8 11

result:

ok AC

Test #9:

score: 0
Accepted
time: 2ms
memory: 3424kb

input:

10

output:

4
2 1 2
4 3 4
6 5 6
8 7 8
4 2 4
8 6 8
3 2 3
10 9 10
5 4 5
6 4 6
11 10 11
8 4 8
7 6 7
9 8 9
10 8 10
11 8 11

result:

ok AC

Test #10:

score: 0
Accepted
time: 2ms
memory: 3316kb

input:

11

output:

4
2 1 2
4 3 4
6 5 6
8 7 8
4 2 4
8 6 8
3 2 3
10 9 10
5 4 5
6 4 6
11 10 11
8 4 8
7 6 7
9 8 9
10 8 10
11 8 11

result:

ok AC

Test #11:

score: 0
Accepted
time: 2ms
memory: 3540kb

input:

12

output:

5
2 1 2
4 3 4
6 5 6
8 7 8
4 2 4
8 6 8
10 9 10
12 11 12
8 4 8
12 10 12
5 4 5
3 2 3
9 8 9
10 8 10
12 8 12
6 4 6
11 10 11
13 12 13
7 6 7
20 20 20

result:

ok AC

Test #12:

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

input:

13

output:

5
2 1 2
4 3 4
6 5 6
8 7 8
4 2 4
8 6 8
10 9 10
12 11 12
8 4 8
12 10 12
5 4 5
3 2 3
9 8 9
10 8 10
12 8 12
6 4 6
11 10 11
13 12 13
7 6 7
20 20 20

result:

ok AC

Test #13:

score: 0
Accepted
time: 2ms
memory: 3356kb

input:

14

output:

6
2 1 2
4 3 4
6 5 6
8 7 8
4 2 4
8 6 8
10 9 10
12 11 12
8 4 8
5 4 5
6 4 6
12 10 12
9 8 9
7 6 7
14 13 14
12 8 12
10 8 10
16 15 16
13 12 13
14 12 14
11 10 11
3 2 3
15 14 15
16 14 16

result:

ok AC

Test #14:

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

input:

15

output:

6
2 1 2
4 3 4
6 5 6
8 7 8
4 2 4
8 6 8
10 9 10
12 11 12
8 4 8
5 4 5
6 4 6
12 10 12
9 8 9
7 6 7
14 13 14
12 8 12
10 8 10
16 15 16
13 12 13
14 12 14
11 10 11
3 2 3
15 14 15
16 14 16

result:

ok AC

Test #15:

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

input:

16

output:

6
2 1 2
4 3 4
6 5 6
8 7 8
4 2 4
8 6 8
10 9 10
12 11 12
8 4 8
5 4 5
6 4 6
12 10 12
9 8 9
7 6 7
14 13 14
12 8 12
10 8 10
16 15 16
13 12 13
14 12 14
11 10 11
3 2 3
15 14 15
16 14 16

result:

ok AC