#K42102. Minimize Cycle Time
Minimize Cycle Time
Minimize Cycle Time
You are given a list of tasks, where each task takes a certain integer duration. Your goal is to compute the minimal cycle time required to complete each task at least once. The cycle time is simply the sum of the durations of all tasks.
For example, if the tasks have durations \(4, 2, 5, 3\), then the minimal cycle time is \(4+2+5+3=14\). Make sure to process the input from standard input (stdin) and output your answer to standard output (stdout).
inputFormat
The first line contains an integer \(n\) representing the number of tasks. The second line contains \(n\) space-separated integers where each integer represents the duration of a task.
outputFormat
Output a single integer denoting the minimal cycle time, which is the sum of all the task durations.
## sample4
4 2 5 3
14