#include <iostream>
#include <cstdio>
#include <vector>
using namespace std;

const int maxn = int(1e5)+5;

int A[maxn];

int main(void)
{
	int n, res = 0;
	scanf("%d", &n);
	for(int i = 1;i <= n;i++) scanf("%d", &A[i]);
	A[0] = 0, A[n+1] = 0;

	for(int i = 0;i <= n;i++) res += abs(A[i]-A[i+1]);

	for(int i = 1;i <= n;i++)
	{
		printf("%d\n", res-abs(A[i-1]-A[i])-abs(A[i+1]-A[i])+abs(A[i-1]-A[i+1]));
	}
}