בבקשה רמז או /וכיוון בשאלה הבאה
Given a set of unsorted numbers , suggest an ADT that supports the max_in_range(i,j) operation in O(logn) time units, and uses O
memory cells. The max_in_range(i,j) operation returns the largest element in the subset . You may use a preprocessing phase, activated once when the ADT is constructed, which takes O
time units. Afterwards, successive calls to max_in_range should take O(logn) time units each. Note: after the initialization of the ADT the numbers cannot be modified, no new numbers will be introduced and no deletions are permitted.