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