#t372. 书架

书架

Cow Stacking

Background

Special for beginners, ^_^

Problem Description

John recently bought a bookshelf to store books about dairy farming, but the bookshelf was quickly filled, leaving only the very top shelf empty.

John has NN cows in total (1≤N≤20,0001 \le N \le 20,000). Each cow has its own height HiH_i (1≤Hi≤10,0001 \le H_i \le 10,000), and the total height of the NN cows is SS. The bookshelf has height BB (1≤B≤S<2,000,000,0071 \le B \le S < 2,000,000,007).

To reach the top of the bookshelf, the cows can step on each other's backs, stacking themselves like a pyramid, until their total height is at least the height of the bookshelf. Of course, the more cows are used, the more dangerous it is. To help John reach the top of the bookshelf, find the solution that uses the minimum number of cows.

Input Format

Line 11: two space-separated integers NN and BB.

Lines 2∼N+12 \sim N+1: line i+1i+1 contains the integer HiH_i.

Output Format

The minimum number of cows needed to reach the height of the bookshelf.

Sample Input 1

6 40
6
18
11
13
19
11

Sample Output 1

3

Constraints

1s, 1024KiB for each test case.