---
id: 6996c675b599baa7b103192d
title: Step 3
challengeType: 1
dashedName: step-3
---

# --description--

In binary search, there is the lowest possible index and the highest possible index.

The lowest possible index represents the leftmost boundary in the current portion of the values being searched within, in this case, `searchList`. The highest possible index, on the other hand, represents the rightmost boundary in the values being searched.

To account for those two, you have to consider the entire array being searched. So, inside the `binarySearch` function, define a `low` variable with a value of `0`, and a `high` variable with a value that accounts for the last index in the array being searched.

# --hints--

You should have a variable named `low` set to `0` in your `binarySearch` function.

```js
assert.match(__helpers.removeJSComments(String(binarySearch)), /(const|let|var)\s+low\s*=\s*0/);
```

You should have a variable named `high` set to `searchList.length - 1` in your `binarySearch` function.

```js
assert.match(
  __helpers.removeJSComments(String(binarySearch)),
  /(const|let|var)\s+high\s*=\s*searchList\.length\s*-\s*1/
);
```

# --seed--

## --seed-contents--

```js
function binarySearch(searchList, value) {
  let pathToTarget = [];
--fcc-editable-region--
  
--fcc-editable-region--
}
```
