Rank Tree in C++
问题 We need ADT having search and rank features. That is, in addition to the interface of STL map, a function 'int get_rank(key)' is required. Standard implementation of such function requires supporting and updating an extra integer field in every node of self-balanced searching tree (e.g., in black-red tree, used in STL map/set). But it seems, STL map/set do not do this. We're looking for a solution based on standard containers (STL, Boost) having the best possible Time Complexity: finding