#BS0000020. Máy sản xuất (Factory Machines)

Máy sản xuất (Factory Machines)

Factory Machines

Source: CSES

Version: Phuoc Hung OJ Extended

Problem Statement

A factory has nn machines. Machine ii needs exactly kik_i seconds to complete one product. After finishing a product, it may immediately start the next one. All machines work independently and simultaneously, and only completed products are counted. Find the minimum integer time required to produce at least tt products.

Input

The first line contains nn and tt. The second line contains k1,…,knk_1,\ldots,k_n.

Output

Print the minimum required time.

Subtasks

  • Subtask 1 — 20%: n=1n=1.
  • Subtask 2 — 30%: 1≤n≤10001\le n\le1000, 1≤t≤1061\le t\le10^6.
  • Subtask 3 — 50%: 1≤n≤2⋅1051\le n\le2\cdot10^5, 1≤t≤1091\le t\le10^9, 1≤ki≤1091\le k_i\le10^9.

Examples

Input

3 7
3 2 5

Output

8

Explanation

After 88 seconds the machines produce 2+4+1=72+4+1=7 products.