Submission #2204307
Source Code Expand
n = int(input()) a = sorted(list(map(int, input().split())), reverse=True) b = sorted(list(map(int, input().split())), reverse=True) c = sorted(list(map(int, input().split())), reverse=True) m1 = [-1 for i in range(n)] j = 0 for i in range(n): while j < n: if a[j] < b[i]: m1[i] = j break j += 1 m3 = [-1 for i in range(n)] j = 0 for i in range(n): while j < n: if b[j] < c[i]: m3[i] = j break j += 1 temp = 0 m2 = [] for i in m1[::-1]: m2.append(temp + (n-i)) temp = m2[-1] m2.reverse() ans = 0 for i in m3: if i != -1: ans += m2[i] print(ans)
Submission Info
Submission Time | |
---|---|
Task | C - Snuke Festival |
User | Kirin0890 |
Language | Python (3.4.3) |
Score | 0 |
Code Size | 684 Byte |
Status | WA |
Exec Time | 371 ms |
Memory | 28340 KB |
Judge Result
Set Name | Sample | All | ||||||
---|---|---|---|---|---|---|---|---|
Score / Max Score | 0 / 0 | 0 / 300 | ||||||
Status |
|
|
Set Name | Test Cases |
---|---|
Sample | s1.txt, s2.txt, s3.txt |
All | 01.txt, 02.txt, 03.txt, 04.txt, 05.txt, 06.txt, 07.txt, 08.txt, 09.txt, 10.txt, 11.txt, 12.txt, 13.txt, 14.txt, 15.txt, 16.txt, 17.txt, 18.txt, 19.txt, 20.txt, 21.txt, 22.txt, 23.txt, 24.txt, 25.txt, 26.txt, 27.txt, 28.txt, 29.txt, s1.txt, s2.txt, s3.txt |
Case Name | Status | Exec Time | Memory |
---|---|---|---|
01.txt | WA | 364 ms | 25116 KB |
02.txt | WA | 371 ms | 25120 KB |
03.txt | WA | 367 ms | 25504 KB |
04.txt | WA | 365 ms | 24824 KB |
05.txt | WA | 342 ms | 19884 KB |
06.txt | WA | 330 ms | 19832 KB |
07.txt | WA | 285 ms | 12616 KB |
08.txt | WA | 289 ms | 12600 KB |
09.txt | WA | 246 ms | 12780 KB |
10.txt | WA | 242 ms | 12784 KB |
11.txt | WA | 221 ms | 12704 KB |
12.txt | WA | 209 ms | 12704 KB |
13.txt | AC | 308 ms | 22220 KB |
14.txt | AC | 289 ms | 22208 KB |
15.txt | WA | 308 ms | 22308 KB |
16.txt | WA | 304 ms | 22308 KB |
17.txt | AC | 294 ms | 22432 KB |
18.txt | AC | 306 ms | 22432 KB |
19.txt | WA | 371 ms | 28340 KB |
20.txt | AC | 172 ms | 12580 KB |
21.txt | AC | 170 ms | 12380 KB |
22.txt | AC | 184 ms | 22720 KB |
23.txt | AC | 327 ms | 22264 KB |
24.txt | WA | 348 ms | 23708 KB |
25.txt | WA | 347 ms | 23424 KB |
26.txt | AC | 17 ms | 3064 KB |
27.txt | AC | 17 ms | 3064 KB |
28.txt | AC | 17 ms | 3064 KB |
29.txt | AC | 17 ms | 3064 KB |
s1.txt | AC | 17 ms | 3064 KB |
s2.txt | AC | 17 ms | 3064 KB |
s3.txt | AC | 17 ms | 3064 KB |