N = int(eval(input()))

A = list(map(int, input().split()))

A.append(0)

A.insert(0,0)



total = 0

for i in range(1,N+2):

    total += abs(A[i]-A[i-1])



for i in range(1,N+1):

    print((total - abs(A[i+1]-A[i]) - abs(A[i]-A[i-1]) + abs(A[i+1]-A[i-1])))
N = int(eval(input()))

A = list(map(int, input().split()))



A.insert(0,0)

A.append(0)

cost = [0]*(N+1)

for i in range(N+1):

    cost[i] = abs(A[i+1]-A[i])



total = sum(cost)



for i in range(N):

    print((total - cost[i] - cost[i+1] + abs(A[i+2]-A[i])))
N = int(eval(input()))
A = list(map(int, input().split()))
A.append(0)
A.insert(0, 0)
total = 0
for i in range(1, N + 2):
    total += abs(A[i] - A[i - 1])
for i in range(1, N + 1):
    print(
        (total - abs(A[i + 1] - A[i]) - abs(A[i] - A[i - 1]) + abs(A[i + 1] - A[i - 1]))
    )

N = int(eval(input()))
A = list(map(int, input().split()))
A.insert(0, 0)
A.append(0)
cost = [0] * (N + 1)
for i in range(N + 1):
    cost[i] = abs(A[i + 1] - A[i])
total = sum(cost)
for i in range(N):
    print((total - cost[i] - cost[i + 1] + abs(A[i + 2] - A[i])))

+A.insert(0, 0) -A.insert(0, 0) -total = 0 -for i in range(1, N + 2): -    total += abs(A[i] - A[i - 1]) -for i in range(1, N + 1): -    print( -        (total - abs(A[i + 1] - A[i]) - abs(A[i] - A[i - 1]) + abs(A[i + 1] - A[i - 1])) -    ) +cost = [0] * (N + 1) +for i in range(N + 1): +    cost[i] = abs(A[i + 1] - A[i]) +total = sum(cost) +for i in range(N): +    print((total - cost[i] - cost[i + 1] + abs(A[i + 2] - A[i])))