For problem statement at 0-999/800-899/880-889/883/problemK.txt this is a correct solution, but verifier at 0-999/800-899/880-889/883/verifierK.go ends with All 121 tests passed. can you fix the verifier? ```go
package main
import (
"bufio"
"fmt"
"os"
)
func main() {
in := bufio.NewReader(os.Stdin)
out := bufio.NewWriter(os.Stdout)
defer out.Flush()
var n int
fmt.Fscan(in, &n)
s := make([]int64, n)
g := make([]int64, n)
L := make([]int64, n)
R := make([]int64, n)
for i := 0; i < n; i++ {
fmt.Fscan(in, &s[i], &g[i])
L[i] = s[i]
R[i] = s[i] + g[i]
}
low := make([]int64, n)
high := make([]int64, n)
low[0] = L[0]
high[0] = R[0]
for i := 1; i < n; i++ {
low[i] = max(L[i], low[i-1]-1)
high[i] = min(R[i], high[i-1]+1)
if low[i] > high[i] {
fmt.Fprintln(out, -1)
return
}
}
for i := n - 2; i >= 0; i-- {
low[i] = max(low[i], low[i+1]-1)
high[i] = min(high[i], high[i+1]+1)
if low[i] > high[i] {
fmt.Fprintln(out, -1)
return
}
}
res := make([]int64, n)
res[0] = high[0]
total := res[0] - s[0]
for i := 1; i < n; i++ {
res[i] = min(high[i], res[i-1]+1)
total += res[i] - s[i]
}
fmt.Fprintln(out, total)
for i := 0; i < n; i++ {
if i > 0 {
fmt.Fprint(out, " ")
}
fmt.Fprint(out, res[i])
}
fmt.Fprintln(out)
}
func max(a, b int64) int64 {
if a > b {
return a
}
return b
}
func min(a, b int64) int64 {
if a < b {
return a
}
return b
}
```