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