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