This is an editorial for the Stable Market Problem from the Codechef April Long Challenge. We discuss how Binary Search is used in solving it.
Problem: https://www.codechef.com/APRIL17/prob...
Binary Search: https://en.wikipedia.org/wiki/Binary_...
Segment Trees: • Segment Tree - Range Queries with Lazy Upd...
Square Root Decomposition: • What is Square Root Decomposition? - Range...
Mo's Algorithm: • Mo's Algorithm: DQUERY from SPOJ
Code:
Mo's Algorithm: https://www.codechef.com/viewsolution...
(Contributed by Shivam Khatri)
Segment Trees: https://www.codechef.com/viewsolution...
(Contributed by Shivam Khatri)
Binary Search: To be added