Problem F
Vinnuálag
Languages
en
is
Knowing all you do now about the ÁFLV course you think to yourself how much effort you would have had to exert, had you worked the same amount every week of the course? That’s exactly what we’ll consider here. To clarify, same effort every week means equally many seconds are spent working on course projects every week.
Each week projects are assigned, and since the course is
over you know how many seconds each project takes to finish.
Each project gives some number of points and each week has a
value
Furthermore only the
Thus the question is now, how many seconds a week do you need?
1 Input
The first line of input contains integers
2 Output
Print the minimum number of seconds needed per week to pass
the course. It is guaranteed that the answer is the same for
all course grades in
Score
Group |
Points |
Constraints |
1 |
20 |
|
2 |
20 |
|
3 |
20 |
The number of projects is at most |
4 |
40 |
No further constraints |
Sample Input 1 | Sample Output 1 |
---|---|
3 2 10 3 5 5 5 5 5 5 4 2 20 20 2 2 8 2 8 8 4 4 |
8 |