From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-0.9 required=5.0 tests=BAYES_00,FORGED_GMAIL_RCVD, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,8e7ac81a215f128c X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII Path: g2news1.google.com!postnews.google.com!y3g2000vbm.googlegroups.com!not-for-mail From: Phil Thornley Newsgroups: comp.lang.ada Subject: Re: Using Red-Black Trees Date: Sat, 13 Nov 2010 04:14:57 -0800 (PST) Organization: http://groups.google.com Message-ID: References: <2419e829-6f45-4075-9005-b9876beb8aaa@r6g2000vbf.googlegroups.com> NNTP-Posting-Host: 88.97.49.112 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1289650497 25176 127.0.0.1 (13 Nov 2010 12:14:57 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Sat, 13 Nov 2010 12:14:57 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: y3g2000vbm.googlegroups.com; posting-host=88.97.49.112; posting-account=Fz1-yAoAAACc1SDCr-Py2qBj8xQ-qC2q User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C),gzip(gfe) Xref: g2news1.google.com comp.lang.ada:15468 Date: 2010-11-13T04:14:57-08:00 List-Id: On Nov 13, 11:20=A0am, Bj=F6rn wrote: > I need a self-balancing binary search tree (for a Bentley/Ottmann > implementation), such as the red-black tree that is now part of > Ada.Containers. I need basic operations like insert/remove, next/prev > and find. However, the GNAT implementation of this data structure > seems a bit scary to me and I'm not really sure how to instantiate the > generics and what operations to use. Would someone be able to provide > some example of usage? And yes, I'am aware of that a lot of the other > container implementations uses this structure. I was hoping for > something a bit more boiled down. > > Regards, > Bj=F6rn Have a look at the stuff under Data Structures on http://www.eternallyconfuzzled.com/jsw_home.aspx There's a lot of good stuff in there (all in C) including iterative algorithms for red-black trees that was used for a SPARK project. Cheers, Phil