Given an array of elements and queries, each asking for the minimum element in a range .
Example: arr - Query : min of = - Query : min of = You're solving the textbook Sparse Table application. Constraints: up to , up to .
##### ###### ##### ### # # ### # # ###### ## ## ## ## ## ## ## # # # # # ## ##### #### ##### # # # # # # # #### ## # ## ## ## ## # # # # # ## ## # ###### ## ### # ### # ######
##### ###### ##### ### # # ### # # ###### ## ## ## ## ## ## ## # # # # # ## ##### #### ##### # # # # # # # #### ## # ## ## ## ## # # # # # ## ## # ###### ## ### # ### # ######
The classic RMQ problem
Given an array of elements and queries, each asking for the minimum element in a range .
Example: arr - Query : min of = - Query : min of = You're solving the textbook Sparse Table application. Constraints: up to , up to .