Day 21: Binary Search Trees

Today I went over binary search trees. I found it interesting how binary search trees are more efficient with O(logn) runtime for inserting and deleting whereas using an array instead would be O(n) runtime for the same operations. For both sorted arrays and binary search trees, binary search will yield O(logn) runtime for search. Main advantages of BST compared to sorted arrays are insert, delete, and search on O(logn) time.