[ABC372D] 楼房视野 (Buildings)
Problem Statement
There are buildings, Building , Building , , Building , arranged in a line in this order. The height of Building is .
For each , find the number of integers satisfying the following condition:
- There is no building taller than Building between Buildings and .
Input
The input is given from Standard Input in the following format:
$N$
$H_1$ $H_2$ $\ldots$ $H_N$
Output
For each , let be the number of satisfying the condition. Print in order, separated by spaces.
Example
5
2 1 4 3 5
3 2 2 1 0
Note
-
Constraints:
-
-
-
-
All input values are integers.
-
Source: ABC372D