Not able to get the solution

Hii…
I am trying to solve question.
https://codeforces.com/contest/1288/problem/C
But couldn’t come up with proper approch and the editorial also look something confusing to me.
Please look at this question.
Thanks.

Hello @ashishnnnnn please wait i will check and tell you give me some time.

Hello @ashishnnnnn have you seen the editorial code?

Yaa… I have seen…
It is talking about … selection with replacement amoung n object of 2m object…
I have tried to see for small value of “N” and “M” on pen and paper…
But this intution didn’t striked me.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.