Comments
0

"If the first number is even, Alice can stay in even numbers".

Why would Alice want to stay on even numbers? How do you know what numbers would be beneficial?

Got it..! :) Thanks. (Corrected the typo).

Ah Sorry , I didn't notice that. Thank You.

In Problem D

Input

7 7
1 2 3 4 5 6 7
2 3 2 1 2 1 1

In the above input, the editorials output is:

4
2 7 3
2 6 2
2 5 1
1 4

which says we need min 4 testcases, i think the min number would be 3 using the following distribution of arrays:

3
2 5 7
3 2 3 6
2 1 4

PLEASE, correct me if I am wrong.