miro's blog

By miro, history, 7 years ago, In English

Suppose we are given a constant c in the beginning and an array. We have range updates(add a value on a range) and range queries(how many occurrences of c are there in a given range?). Is it possible to effectively perform these queries? I know how to do that for counting the number of minimums/maximums, but I'm not sure if there is a way do that for a constant c given in the beginning. Thanks in advance.

Full text and comments »

  • Vote: I like it
  • +15
  • Vote: I do not like it