Binary Search Tree(BST) is a binary tree, where the value of left child is less than value of parent and value of right child is greater than value of parent. In BST, Operations like insert, update,search have running time complexity is O(log(n)) and worst case time complexity is O(n) where n is number of elements. BST is generally used in searching algorithm. In this tutorial we will be creating Binary Search Tree
Example of Binary Search Tree
Given data : 10, 25, 2, 1, 14, 30, 5, 7 …
Java Stream API has been introduced in Java 8 which majorly focuses on providing various method for operation on Source. It operates around Source as wrapper making bulk operation fast and in few lines.
Stream bring functional programming to Java and heavily uses lambda expression for its implementation. ParallelStream can be used for multi-threaded operations.
Stream operations can be classified into two sets
- Intermediate Operations
- Terminal Operations