Submission #1997033


Source Code Expand

# coding:utf-8

x=int(input())
member=list(map(int, input().split()))

table=(10**9)*[int(0)]
ans=0
for i in range(x):
    table[member[i]] += 1

    if (table[member[i]] != member[i]):
        ans += 1
    else:
        ans -= (member[i]-1);


print(ans)

'''
# {{{

# }}}
'''

Submission Info

Submission Time
Task C - Good Sequence
User eryuk888
Language Python (3.4.3)
Score 0
Code Size 301 Byte
Status RE
Exec Time 43 ms
Memory 14688 KB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 0 / 300
Status
RE × 5
RE × 18
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 RE 17 ms 3064 KB
0_01.txt RE 17 ms 3060 KB
0_02.txt RE 17 ms 3060 KB
0_03.txt RE 17 ms 3060 KB
0_04.txt RE 17 ms 3060 KB
1_00.txt RE 17 ms 3060 KB
1_01.txt RE 17 ms 3060 KB
1_02.txt RE 33 ms 4660 KB
1_03.txt RE 40 ms 13964 KB
1_04.txt RE 41 ms 13936 KB
1_05.txt RE 41 ms 13936 KB
1_06.txt RE 43 ms 14024 KB
1_07.txt RE 40 ms 14024 KB
1_08.txt RE 41 ms 13920 KB
1_09.txt RE 43 ms 14212 KB
1_10.txt RE 41 ms 13596 KB
1_11.txt RE 41 ms 14688 KB
1_12.txt RE 40 ms 13688 KB