N = input()
a = 0
c = 0
while a != N:
    a = a + 1
    while c < 1000:
        k = input()
        c = c + k
print(c)