Binary Search

Objective

Search for the target element in the sorted/ordered list, which might be present. To search, use binary search strategy.

Experiment Setup

The Binary Search experiment consists of a list of numbers which are hidden. The selectable items are in "GREY". You can select atmost log(N) items from the list in succession. At the end of the process, you will be able to verify the process using the "Show All" control button.

On clicking one item, the selectable array will be changed according to the chosen index, associated number will be shown. The elements Left/Right to the chosen index will become non selectable. Non selectable items will be shown in "RED" and the background will indicate whether the number is the search target.

Procedure

Follow the given steps to perform the experiment.

  1. Select an item from the grey items.
  2. Check if the number is the search Target.If not, then repeat step 1 and 2 again.