SPOJ GSS4 (BIT+UFDS) HELP WITH IDEA

Revision en2, by har_vi, 2016-08-17 21:55:36

Range updates or range set with BIT/fenwick tree

SPOJ/GSS4

  1. How should I do range updates with BIT using Union Find Data Structure?what would be expected complexity?
  2. In this case max updates can be 7.N*logN but what if we set number in range to random number which don't have such relation with the input.Would it still possible to do it with BIT/fenwick tree or there's any other approach to set elements in range to a given.

Thanks!

Tags gss4, fenwick tree, range update, union find

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en2 English har_vi 2016-08-17 21:55:36 81 Tiny change: '----------[GSS4](http' -
en1 English har_vi 2016-08-17 21:51:39 466 Initial revision (published)