N = int(eval(input()))

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

cums = [0]

for a,b in zip(src,src[1:]):

    cums.append(cums[-1] + abs(a-b))



for i in range(N):

    print((cums[i] + abs(src[i] - src[i+2])   - cums[i+2] + cums[-1]))

N = int(input())

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

cuml = [0]

for a,b in zip(A,A[1:]):

    cuml.append(cuml[-1] + abs(a-b))

cumr = [cuml[-1]-c for c in cuml[::-1]][::-1]



ans = [cuml[i] + cumr[i+2] + abs(A[i] - A[i+2]) for i in range(N)]

print(*ans, sep='\n')

N = int(eval(input()))
src = [0] + list(map(int, input().split())) + [0]
cums = [0]
for a, b in zip(src, src[1:]):
    cums.append(cums[-1] + abs(a - b))
for i in range(N):
    print((cums[i] + abs(src[i] - src[i + 2]) - cums[i + 2] + cums[-1]))

N = int(input())
A = [0] + list(map(int, input().split())) + [0]
cuml = [0]
for a, b in zip(A, A[1:]):
    cuml.append(cuml[-1] + abs(a - b))
cumr = [cuml[-1] - c for c in cuml[::-1]][::-1]
ans = [cuml[i] + cumr[i + 2] + abs(A[i] - A[i + 2]) for i in range(N)]
print(*ans, sep="\n")

-N = int(eval(input())) -src = [0] + list(map(int, input().split())) + [0] -cums = [0] -for a, b in zip(src, src[1:]): -    cums.append(cums[-1] + abs(a - b)) -for i in range(N): -    print((cums[i] + abs(src[i] - src[i + 2]) - cums[i + 2] + cums[-1])) +N = int(input()) +A = [0] + list(map(int, input().split())) + [0] +cuml = [0] +for a, b in zip(A, A[1:]): +    cuml.append(cuml[-1] + abs(a - b)) +cumr = [cuml[-1] - c for c in cuml[::-1]][::-1] +ans = [cuml[i] + cumr[i + 2] + abs(A[i] - A[i + 2]) for i in range(N)] +print(*ans, sep="\n")