import std.stdio, std.algorithm, std.range, std.conv, std.string, std.math;
import core.stdc.stdio;
// foreach, foreach_reverse, writeln

void main() {
	int n;
	scanf("%d", &n);
	int[] a = new int[n+2];
	foreach (i; 0..n) {
		scanf("%d", &a[i+1]);
	}
	int ans = 0;
	foreach (i; 0..n+1) {
		ans += abs(a[i+1]-a[i]);
	}
	foreach (i; 1..n+1) {
		int diff = 0;
		diff += abs(a[i]-a[i-1]);
		diff += abs(a[i+1]-a[i]);
		diff -= abs(a[i+1]-a[i-1]);
		writeln(ans-diff);
	}
}