
import java.lang.Math.abs
import java.util.*


fun main(args: Array<String>) {

    with(Scanner(System.`in`)) {
        val n = nextInt()
        val a = Array(n+2, {0})
        var total = 0
        (1..n).forEach {
            a[it] = nextInt()
            total += abs(a[it] - a[it-1])
        }
        total += abs(a[n])
        (1..n).forEach {
            println(total + abs(a[it+1]-a[it-1]) - abs(a[it]-a[it-1]) - abs(a[it+1]-a[it]))
        }
    }

}