#K80672. Minimal Maximum Storage Utilization
Minimal Maximum Storage Utilization
Minimal Maximum Storage Utilization
Given n warehouses, each with a specified storage capacity, your task is to determine the minimal possible value of the maximum storage utilization among all non-empty subsets of these warehouses. In simpler terms, you are required to find the smallest storage capacity from the list since, for any non-empty subset, the maximum storage utilization is at least as large as the minimum capacity among the warehouses in that subset.
Formally, if the storage capacities are given by the set \(S = \{s_1, s_2, \dots, s_n\}\), the answer is $$\min_{1 \leq i \leq n} s_i.$$
inputFormat
The input is read from stdin and is formatted as follows:
- The first line contains a single integer n (1 ≤ n ≤ 105), representing the number of warehouses.
- The second line contains n space-separated integers, where each integer represents the storage capacity of a warehouse.
outputFormat
Output a single integer to stdout that denotes the minimal maximum storage utilization among all the warehouses (i.e. the minimum storage capacity).## sample
1
7
7