Win a copy of Testing JavaScript Applications this week in the HTML Pages with CSS and JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

TreeSet has Red and White Structure , whats that suppose to mean?

 
Ranch Hand
Posts: 1087
Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
TreeSet has Red and White Structure , whats that suppose to mean
 
Ranch Hand
Posts: 781
Netbeans IDE Ubuntu Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Vishal Hegde wrote:TreeSet has Red and White Structure , whats that suppose to mean



A 'red-black' tree is a tree data structure where nodes are either coloured 'red' or 'black' depending whether or not they are paired with other nodes. This approach allows the tree to be kept pretty close to balanced at all times as nodes are added and removed. Google will find you the detail.
 
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Red-black trees are balanced, so searches traverse a minimum number of nodes. The wikipedia article is a good place to start.
 
I'm sure glad that he's gone. Now I can read this tiny ad in peace!
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
    Bookmark Topic Watch Topic
  • New Topic