while True: a = map(int,raw_input().strip().split()) n,b=a[0],a[1:] s=0 for i in range(len(b)): if b[i]%2==1: s=s+b[i] print s