#C5833. Block Height Equalization
Block Height Equalization
Block Height Equalization
You are given n blocks with various heights. In a single operation, you can increase the height of any block by any amount. Your goal is to minimize the difference between the tallest and the shortest block.
It turns out that since you can increase the height of any block arbitrarily, you can always raise the shorter blocks to match the tallest one. Therefore, the minimum possible difference is \(0\).
Note: All operations are assumed to be performed in a way to achieve this minimum difference.
inputFormat
The first line of the input contains an integer \(n\) — the number of blocks. The second line contains \(n\) space-separated integers representing the heights of the blocks.
outputFormat
Output a single integer — the minimum possible difference between the tallest and the shortest block after performing the operations.
## sample1
5
0