The Hermit stands alone on the top of a mountain with a lantern in his hand. The snow-capped mountain range symbolises the Hermit’s spiritual achievement, growth and accomplishment. He has chosen this path of self-discovery and, as a result, has reached a heighted state of awareness
dhh loves to listen to radio. There are $N$ radio stations on a number axis, and the i-th station is located at $x_i$ = $i$. The broadcasting scope of the $i$-th station is $rad_i$ , which means stations in the interval [$i$ - $rad_i$ + 1, $i$ + $rad_i$ - 1] can receive the signal from the $i$-th station. For some unknown reason, the left boundary that can receive the $i$-th station’s signal is non-descending, which meansi $i$ - $rad_i$ + 1 ≤ $i$ + 1 - $rad_{i+1}$ + 1.
Now dhh wants to listen to the radio from station $i$, and he finds that the station $k$, satisfying both of the following conditions, can receive perfect signal from the station $i$:
k < i and station k can receive station i’s signal.
There exists another station $j$($k$ ≤ $j$ < $i$) such that station $k$ and $i$ can both receive the signal from station $j$ and the distance between station $k$ and $j$ is greater than or equal to the distance between station $j$ and $i$.
Now dhh wonders for each station $i$, how many stations can receive the perfect signal from station $i$.