from collections import deque

n = int(eval(input()))

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

A.appendleft(0)

A.append(0)

ans = 0

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

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

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

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

    print((ans-d+abs(A[i-1]-A[i+1])))

n = int(eval(input()))

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

A.append(0)

A.insert(0, 0)

ans = 0

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

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

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

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

    print((ans-d+abs(A[i-1]-A[i+1])))

from collections import deque

n = int(eval(input()))
A = deque(list(map(int, input().split())))
A.appendleft(0)
A.append(0)
ans = 0
for i in range(1, n + 2):
    ans += abs(A[i] - A[i - 1])
for i in range(1, n + 1):
    d = abs(A[i] - A[i - 1]) + abs(A[i + 1] - A[i])
    print((ans - d + abs(A[i - 1] - A[i + 1])))

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

-from collections import deque - -A = deque(list(map(int, input().split()))) -A.appendleft(0) +A = list(map(int, input().split())) +A.insert(0, 0)