WOUT - Editorial

Hi ,
I used the following approach for solving the problem without using bit/segment trees.

https://www.codechef.com/viewsolution/7726107

Hope this helps!!

@rcsldav2017

Dude please tell me the easy way, this editorial has just crossed my head.

I am getting wrong answer in 2 sections of subtask 2. Could somebody look and point out what me be wrong.
Here is a link to my solution: https://www.codechef.com/submit/complete/11254238

Why is r-1=N? Couldn’t get that.

also, if you know more questions like this please let me know. Thanks in advance for that

can you please explain your code?

yes … tutorials are given to make things easier … but some tutorials
uses so much extra things which are really not required . .

@rcsldav yes

this is not a dp question too a far and large extent … why wrong tag ??

1 Like