diff --git a/README.md b/README.md index fab13c7..9704078 100644 --- a/README.md +++ b/README.md @@ -165,11 +165,9 @@ bst.traverse(node => console.log(node.getValue()), 'preOrder'); removes a value's node (if exists) from the tree. ```javascript +console.log(bst.find(30).getValue()); // 30 bst.remove(30); -let n50 = bst.find(50); -let n40 = bst.find(40); -console.log(n50.getLeft().getValue()); // 40 -console.log(n40.getLeft().getValue()); // 20 +console.log(bst.find(30)); // null ``` **.clear()** diff --git a/package.json b/package.json index f4dcae9..cf8fbfc 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@datastructures-js/binary-search-tree", - "version": "1.0.6", + "version": "1.0.7", "description": "binary search tree implementation in javascript", "main": "index.js", "scripts": {