Find the difference between the greatest and least bed measurement.
Task: Find maximum minus minimum.
Input format: n followed by n integers.
Output format: One integer: max(a)-min(a).
Constraints: 1 <= n <= 100000; -10^9 <= a[i] <= 10^9
Edge rules: Apply the stated zero, tie, boundary, and ordering conventions exactly.