AT_abc389_e [ABC389E] Square Price
Description
There are $ N $ types of products, each having $ 10^{100} $ units in stock.
You can buy any non-negative number of units of each product. To buy $ k $ units of the $ i $ -th product, it costs $ k^2 P_i $ yen.
If your total purchase cost is at most $ M $ yen, what is the maximum number of units you can buy in total?
Input Format
The input is given from Standard Input in the following format:
> $ N $ $ M $ $ P_1 $ $ \ldots $ $ P_N $
Output Format
Print the answer.
Explanation/Hint
### Sample Explanation 1
If you buy one unit of the 1st product and two units of the 2nd product, the total purchase cost is $ 1^2 \times 4 + 2^2 \times 1 = 8 $ . It is impossible to buy four or more units in total with a total cost of at most $ 9 $ yen, so the answer is $ 3 $ .
### Constraints
- $ 1 \leq N \leq 2 \times 10^{5} $
- $ 1 \leq M \leq 10^{18} $
- $ 1 \leq P_i \leq 2 \times 10^{9} $
- All input values are integers.