May i have some ideas on how to approach this problem?Very simple question,but the best question i have come across till date!
Link: Mass change Queries
Please abstain from providing complete solution
May i have some ideas on how to approach this problem?Very simple question,but the best question i have come across till date!
Link: Mass change Queries
Please abstain from providing complete solution
if you know sqrt decomposition then thought of applying the same. And yes it’s a very nice question
Using Sqrt decomposition it can be done. By storing indices for each element in the given array blockwise and manipulating them.
Awesome thanks!
Happy new year If you can then please answer this : help in understanding expectation! - general - CodeChef Discuss
Will be a great help
I finding difficulty in storing the indices for each unique element in the given array blockwise.