コード例 #1
0
        public void TestBSTRemoveAt()
        {
            var tree = new BinarySearchTree<int>() { 40, 11, 62, 43, 34, 16, 10, 63 };

            Assert.AreEqual(34, tree[3], "Checking that 34 is on the 3. place in the array.");
            tree.RemoveAt(3);
            Assert.IsFalse(tree.Contains(34), "Checking if 34 is in the tree.");
        }