Setting a Time Limit

Time limit2sMemory limit512 MB

Summary
Given n runtimes in milliseconds and a factor s, output the smallest whole number of seconds that is at least s times the largest runtime.
Level

Easy2 of 10

Topics
Math, Implementation, Array
Solved
No attempts yet

Problem

Your Chief Judge needs help! He needs to set the time limit for a problem in the problem set. He has nn solutions written by his judges. He knows how long each runs in the contest environment, in milliseconds. He wants to set the time limit to be at least ss times the slowest solution from his judges, but as small as possible, and he wants it to be an integral number of seconds. Can you help him?

Input

Each input consists of a single test case. Your program may be run multiple times on different inputs.

Each test case begins with a line containing two space-separated integers nn (1≤n≤1001 \le n \le 100) and ss (1≤s≤201 \le s \le 20), where nn is the number of solutions from judges and ss is the multiplying factor.

The next line contains nn space-separated integers mm (1≤m≤2,0001 \le m \le 2{,}000), which are the number of milliseconds it takes for some judge's solution to run in the contest environment.

Output

Output a single integer, the time limit to set for this problem. It is in seconds, and it is the smallest time that is at least ss times the slowest judge's solution.

Examples2

  1. Example 1

    Input
    2 5
    200 250
    
    Expected output
    2
    
  2. Example 2

    Input
    3 4
    47 1032 1107
    
    Expected output
    5