c = int(input()) l = list(map(int, input().strip().split())) sum = 0 for n in range(0, c): sum += (n + 1)*l[n] print(sum)