N = int(input()) sequence = list(map(int,input().split())) m = int(input()) count = sequence.count(m) print(count)