i,ip=int,input son, n, w = i(ip())+i(ip()), i(ip()), 0 book = sorted([i(ip()) for _ in range(n)]) for j in book: w += 1 - 1/book.count(j) print(round(w)*son)