from copy import deepcopy
N = int(input())
A = list(map(int, input().split()))
A = [0] + A + [0]
dist = []
for i in range(N + 1):
    dist.append(abs(A[i] - A[i + 1]))
S = sum(dist)
for i in range(1, N + 1):
    print(S + abs(A[i + 1] - A[i - 1]) - abs(A[i] - A[i + 1]) - abs(A[i - 1
        ] - A[i]))

cf367b84865b8de2dfdb680f7e27f436921bd737
<mask token>

<mask token>
for i in range(N + 1):
    dist.append(abs(A[i] - A[i + 1]))
<mask token>
for i in range(1, N + 1):
    print(S + abs(A[i + 1] - A[i - 1]) - abs(A[i] - A[i + 1]) - abs(A[i - 1
        ] - A[i]))

<mask token>
N = int(input())
A = list(map(int, input().split()))
A = [0] + A + [0]
dist = []
for i in range(N + 1):
    dist.append(abs(A[i] - A[i + 1]))
S = sum(dist)
for i in range(1, N + 1):
    print(S + abs(A[i + 1] - A[i - 1]) - abs(A[i] - A[i + 1]) - abs(A[i - 1
        ] - A[i]))

from copy import deepcopy
N = int(input())
A = list(map(int, input().split()))
A = [0] + A + [0]
dist = []
for i in range(N + 1):
    dist.append(abs(A[i] - A[i + 1]))
S = sum(dist)
for i in range(1, N + 1):
    print(S + abs(A[i + 1] - A[i - 1]) - abs(A[i] - A[i + 1]) - abs(A[i - 1
        ] - A[i]))
