#K69047. Maximum Box Value
Maximum Box Value
Maximum Box Value
You are given n boxes, each containing an integer value. The goal is to compute the maximum value that can be achieved on a single box by combining all the given values.
The result can be mathematically represented as:
$$\text{Result} = \sum_{i=1}^{n} a_i$$
where \(a_i\) represents the value on the \(i^{th}\) box.
inputFormat
The input is provided via standard input (stdin) as follows:
- The first line contains an integer
n
, the number of boxes. - The second line contains
n
space-separated integers, where each integer represents the value on a box.
outputFormat
Output a single integer to standard output (stdout), which is the maximum possible value on a single box. This value is the sum of all the box values, given mathematically by:
$$\sum_{i=1}^{n} a_i$$
## sample3
1 2 3
6