Red black trees: Difference between revisions

Replaced lang tags with syntaxhighlight ones
No edit summary
(Replaced lang tags with syntaxhighlight ones)
 
Line 3:
== C# ==
 
<langsyntaxhighlight lang="csharp">// Set6 - Red/Black (3State) Sets
 
using System;
Line 747:
 
public EntryAlreadyExistsException() : base(message) { }
}</langsyntaxhighlight>
 
== Standard ML ==
 
<langsyntaxhighlight lang="sml">(* These red-black trees are manipulated using zippers.
* It is up to the user to insert the elements in the correct place.
* However, the implementation guarantees that, when a tree is rebalanced,
Line 876:
fun cons (x, ss) = ins (x ^ Empty :: nil, ss)
fun fromDesc xs = foldl upd Empty (foldl cons nil xs)
end</langsyntaxhighlight>