Type: Default 1000ms 256MiB

Monster

You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.

Monster

一个怪兽来到了高桥所居住的小镇,已知怪兽有mm滴血,高桥有nn颗子弹,每颗子弹可以让怪兽减aia_{i}滴血。高桥想知道他至少需要几颗子弹才能打死这个怪兽。

输入格式

nn mm

a1a_{1} a2a_{2} ...ana_{n}

输出格式

高桥打死这个怪兽至少所需的子弹颗数(如果打不死怪兽输出-1)。

4 10
4 2 6 3
2

n<100n<100,1<=mm<=10510^{5},1<=aia_{i}<=101810^{18}

#######################

Not Attended
Status
Done
Rule
Ledo
Problem
9
Start at
2025-2-10 8:30
End at
2025-2-14 8:30
Duration
96 hour(s)
Host
Partic.
4