Edge Rewrite
// HTMLRewriter · presentation

This page was redesigned at the edge.

Cloudflare fetched the original article and streamed it through HTMLRewriter to apply an entirely new visual system without rebuilding the source page.

// request.cf · coarse context

A page that knows where it met you.

Only coarse request metadata is shown. This demo does not display or persist visitor IP addresses.

Country
US
Cloudflare location
CMH
Connection
HTTP/2
Language
Not provided

Ray ID: a226a07209ef4b2a

Jump to content

Talk:Order statistic tree

Page contents not supported in other languages.
Add topic
From Wikipedia, the free encyclopedia
Latest comment: 10 years ago by Soronel~enwiki in topic Rope

Rank algorithm should be checked

[edit]

Anonymous user 178.4.21.216 broke the Select algorithm by making it one-indexed (in contradiction to the comment), then added a Rank algorithm as follows:

function Rank(T, x)
    // Returns the position of x in the linear sorted list of elements of the tree T
    r ← size[left[x]] + 1
    y ← x
    while y ≠ T.root
         if y = right[y.p]
              r ← r + size[left[y.p]] + 1
         y ← y.p
    return r

I'm not sure what y.p is supposed to be, a parent pointer? Also, this probably uses a one-indexed convention. QVVERTYVS (hm?) 14:37, 29 June 2014 (UTC)Reply

Rope

[edit]

Would the tree used by Rope (data structure) be considered a variant of an order statistic tree?

The rope's value/weight system seems like a very similar concept, just allowing a node to have a value other than 1.

Soronel~enwiki (talk) 07:23, 7 March 2016 (UTC)Reply