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
Awesome thanks!
Happy new year If you can then please answer this : https://discuss.codechef.com/questions/120548/help-in-understanding-expectation
Will be a great help
Using Sqrt decomposition it can be done. By storing indices for each element in the given array blockwise and manipulating them.
I finding difficulty in storing the indices for each unique element in the given array blockwise.