How to compute answer to queries of type l,r,k which finds number of elements in an array which occurs atleast k times in range l to r ? How to use Mo's algorithm?
Asked
Active
Viewed 77 times
1 Answers
0
If you have offline queries, you can use Mo's algorithm.
The following link is quite helpful.Anudeep's blog - Mo's Algorithm

Atul Chaturvedi
- 61
- 1
- 5