Submission #2525351
Source Code Expand
from pprint import pprint n=int(input()) a=[int(i) for i in input().split()] d={} cnt=0 for i in a: if str(i) not in d: d[str(i)]=1 else: d[str(i)]+=1 for i in d: if int(i)>d[i]: cnt+=d[i] else: if int(i)<d[i]: cnt+=d[i]-int(i) print(cnt)
Submission Info
Submission Time | |
---|---|
Task | C - Good Sequence |
User | kilattoeruru |
Language | Python (3.4.3) |
Score | 300 |
Code Size | 316 Byte |
Status | AC |
Exec Time | 159 ms |
Memory | 23964 KB |
Judge Result
Set Name | Sample | All | ||||
---|---|---|---|---|---|---|
Score / Max Score | 0 / 0 | 300 / 300 | ||||
Status |
|
|
Set Name | Test Cases |
---|---|
Sample | 0_00.txt, 0_01.txt, 0_02.txt, 0_03.txt, 0_04.txt |
All | 0_00.txt, 0_01.txt, 0_02.txt, 0_03.txt, 0_04.txt, 1_00.txt, 1_01.txt, 1_02.txt, 1_03.txt, 1_04.txt, 1_05.txt, 1_06.txt, 1_07.txt, 1_08.txt, 1_09.txt, 1_10.txt, 1_11.txt, 1_12.txt |
Case Name | Status | Exec Time | Memory |
---|---|---|---|
0_00.txt | AC | 22 ms | 3572 KB |
0_01.txt | AC | 22 ms | 3572 KB |
0_02.txt | AC | 22 ms | 3572 KB |
0_03.txt | AC | 22 ms | 3572 KB |
0_04.txt | AC | 22 ms | 3572 KB |
1_00.txt | AC | 22 ms | 3572 KB |
1_01.txt | AC | 22 ms | 3572 KB |
1_02.txt | AC | 95 ms | 5420 KB |
1_03.txt | AC | 110 ms | 14476 KB |
1_04.txt | AC | 108 ms | 14448 KB |
1_05.txt | AC | 117 ms | 14448 KB |
1_06.txt | AC | 113 ms | 14664 KB |
1_07.txt | AC | 105 ms | 14268 KB |
1_08.txt | AC | 116 ms | 14944 KB |
1_09.txt | AC | 130 ms | 14080 KB |
1_10.txt | AC | 142 ms | 16372 KB |
1_11.txt | AC | 148 ms | 17132 KB |
1_12.txt | AC | 159 ms | 23964 KB |