QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#83100#3414. Diagrams & Tableauxxiaowuc1AC ✓15ms8008kbPython3392b2023-03-01 05:51:292023-03-01 05:51:32

詳細信息

Test #1:

score: 100
Accepted
time: 15ms
memory: 7988kb

input:

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

output:

1
2
20
20

result:

ok 4 lines

Test #2:

score: 0
Accepted
time: 10ms
memory: 8008kb

input:

4 7 7 7 2
5
5 6 6 4 2 2
7
6 6 6 4 3 2 1
7
7 7 7 7 7 4 2 2
7
7 7 7 7 7 5 3 2
7
6 6 6 5 3 2 1
7
7 7 7 7 7 5 2 2
7
4 7 6 4 1
5
6 6 6 6 6 4 2
7
5 6 6 6 3 1
7
7 7 7 7 7 7 3 2
7
4 7 7 6 1
5
6 6 6 6 4 2 1
7
6 6 6 6 5 2 1
7
4 7 7 6 2
5
6 6 6 6 6 6 6
7
4 7 6 4 2
5
5 6 6 6 5 3
7
7 7 7 7 6 3 2 2
7
7 7 7 7 5 4 ...

output:

6930
2656192
2838528
194040
124740
3492720
138600
31185
336798
3430350
19404
15840
2587200
1892352
15400
924
26730
1778700
465696
519750
21560
2097152
4752
462
56
2276736
12936
1155
224
66528
473088
3201660
13860
6468
41580
4125
20
623700
8
242550
155232
762300
26400
5292540
727650
360
2475
23100
10...

result:

ok 108 lines