# Another 'thing I didn't know but should've done' - the magic of different Binary Search Tree implementations

<datetime class="hidden">2006-09-07T00:00</datetime>
<!-- category -- mostlylucidcouk, Imported -->

## 
Another 'thing I didn't know but should've done' - the magic of different Binary Search Tree implementations 

posted on Wednesday, December 10, 2003 3:32 PM

Hmm...was fishing through [GotDotNet user samples](http://www.gotdotnet.com/community/usersamples/) when I came across [this](http://www.gotdotnet.com/Community/UserSamples/Details.aspx?SampleGuid=6644D97B-B743-47D9-A0E7-A207EEBFB0F9)...now this is an extermely cool implementation of different types of Binary Search collections - now I have never used the [Sorted List collection](http://msdn.microsoft.com/library/en-us/cpref/html/frlrfsystemcollectionssortedlistclasstopic.asp) before - but I should've done! It has a very cool feature which lets you access elements by value or key. The GotDotNet ones do pretty much the same thing except they're more efficient for certain types of data; see [here for more info on Splay Trees](http://www.link.cs.cmu.edu/splay/) and [here for info on Red-Black trees](http://www.theory.csc.uvic.ca/~cos/inf/tree/RedBlackTree.html) and [here for info on Binary Search trees](http://www.cogs.susx.ac.uk/local/teach/dats/notes/html/node59.html) - pretty useful and could help optimise in-memory searches!