How to find rank ( position it holds when heap is sorted in descending
order, first one having rank one)  of a element at a particular index in a
maxheap? For Example

Given max heap    6,3,4,2,1,3,0
Sorted heap:         6,4,3,3,2,1,0
Rank of element t index 3 (element with value 2, indexing starts from 0) is
5.

We can use additional storage.


-Thanks
Bujji

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].

Reply via email to