n = int(eval(input()))

a = [0] +list(map(int, input().split()))+[0]

money = [0]

for i in range(n+1):

  money.append(abs(a[i]-a[i+1]))



ans = sum(money)

for i in range(n):

  print((ans-sum(money[i+1:i+3])+abs(a[i]-a[i+2])))
n = int(eval(input()))

A = [0]+ list(map(int, input().split())) + [0]

a = [0]

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

    a.append(abs(A[i-1]-A[i]))

ans = sum(a)

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

    x = ans - a[i] - a[i+1]

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

    print(x)
n = int(eval(input()))
a = [0] + list(map(int, input().split())) + [0]
money = [0]
for i in range(n + 1):
    money.append(abs(a[i] - a[i + 1]))
ans = sum(money)
for i in range(n):
    print((ans - sum(money[i + 1 : i + 3]) + abs(a[i] - a[i + 2])))

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

-a = [0] + list(map(int, input().split())) + [0] -money = [0] -for i in range(n + 1): -    money.append(abs(a[i] - a[i + 1])) -ans = sum(money) -for i in range(n): -    print((ans - sum(money[i + 1 : i + 3]) + abs(a[i] - a[i + 2]))) +A = [0] + list(map(int, input().split())) + [0] +a = [0] +for i in range(1, n + 2): +    a.append(abs(A[i - 1] - A[i])) +ans = sum(a) +for i in range(1, n + 1): +    x = ans - a[i] - a[i + 1] +    x += abs(A[i - 1] - A[i + 1]) +    print(x)