示例#1
0
        public BinarySearchTree BuildTree(TreeAssertData data)
        {
            BinarySearchTree tree = new BinarySearchTree();

            foreach (var key in data.input)
                tree.Insert(key);

            return tree;
        }
示例#2
0
        public RBTree BuildTree(TreeAssertData data)
        {
            RBTree tree = new RBTree();

            foreach (var key in data.input)
                tree.Insert(key);

            return tree;
        }