Bifalgorithm post
Binary search algorithm is a searching algorithm used in a sorted array by repeatedly dividing the search interval in half. Divide the search space into two halves by finding the middle index mid. Compare the middle element of the search space with the key. If the key is found at middle element, the process is terminated. If the key is not found at middle element, choose which half will be used as the next search space. If the key is smaller than the middle element, then the left side is used for next search. If the key is larger than the middle element, then the right side is used for next search.
Binary search algorithm is a searching algorithm used in a sorted array by repeatedly dividing the search interval in half. Divide the search space into two ha…
Ideas in this flowchart
- Binary Search Algorithm
- Process Overview
- Divide Search Space
- Find Middle Index
- Compare Middle Element with Key
- Key Found
- Terminate Process
- Key Not Found
- Choose Next Search Space
- Key Smaller Than Middle Element
- Use Left Side
- Key Larger Than Middle Element
- Use Right Side