import sys sys.setrecursionlimit(10**7) def I(): return int(sys.stdin.readline().rstrip()) def MI(): return map(int,sys.stdin.readline().rstrip().split()) def LI(): return list(map(int,sys.stdin.readline().rstrip().split())) def LI2(): return list(map(int,sys.stdin.readline().rstrip())) def S(): return sys.stdin.readline().rstrip() def LS(): return list(sys.stdin.readline().rstrip().split()) def LS2(): return list(sys.stdin.readline().rstrip()) N,X,Y = MI() A = LI() SA = sum(A) S = [X-a for a in A] T = [Y-a for a in A[::-1]] U = [S[0]] x = S[0] y = 0 for i in range(1,N-1): s = S[i] if y+s > 0 or s > x: if x+y > 0: x += y+s else: x = s y = 0 else: y += s U.append(x) V = [T[0]] x = T[0] y = 0 for i in range(1,N-1): t = T[i] if y+t > 0 or t > x: if x+y > 0: x += y+t else: x = t y = 0 else: y += t V.append(x) for i in range(1,N-1): print(SA+U[i-1]+V[N-2-i])