while True: try: s=0 l = list(map(int,input().split())) for i in range(1,l[0]+1): if l[i]%2 != 0: s+=l[i] print(s) except EOFError: break