You are the Chief Examiner of a unit and you have assignments that are needed to be marked. You have
TAs which mark assignments in parallel. The
-th TA can mark an assignmnt every
minutes. What is the minimum amount of time that it will take to mark all assignments?
Input
The first line will contain integers and
. The number of TAs and number of assignments to mark, respectively.
The second line contains
integers,
, the time it takes for each TA to mark 1 assignment.
Output
Output the minimum time needed to mark every assignment.
Constraints
Example 1
Input
10 123
7 7 4 6 3 8 9 8 5 1
Output
49
Example 2
Input
10 63
8 10 4 6 3 6 9 8 4 5
Output
36
Comments