All submissions for this problem are available.
Submission days are approaching. Kirve wants to complete his K pending assignments as soon as possible. He can write at max N pages with his pen. He cannot afford to buy a new pen so he has to write with this pen only.
Each assignment he wants to complete may have different number of pages.He decides to complete the assignments in given order only. He is weak in maths,help him to find the number of assignments he can complete.
- $1 \leq T \leq 100 $
- $1 \leq K \leq 10000 $
- $1 \leq N \leq 10000000 $
- $1 \leq A[i] \leq 1000 $
1 2 3 4 5
He can complete at most 2 assignments.
|Time Limit:||1 sec|
|Source Limit:||50000 Bytes|
|Languages:||C, CPP14, JAVA, PYTH, PYTH 3.6, PYPY, CS2, PAS fpc, PAS gpc, RUBY, PHP, GO, NODEJS, HASK, rust, SCALA, swift, D, PERL, FORT, WSPC, ADA, CAML, ICK, BF, ASM, CLPS, PRLG, ICON, SCM qobi, PIKE, ST, NICE, LUA, BASH, NEM, LISP sbcl, LISP clisp, SCM guile, JS, ERL, TCL, kotlin, PERL6, TEXT, SCM chicken, PYP3, CLOJ, COB, FS|
Fetching successful submissions