Converted to Red Black Tree.

Add destroy function.