One possible use of the modulo, or remainder, operation is to “wrap around” to the beginning of an array when you reach its end. Consider this code:

```
const arr = [1, 2, 3]
const arrLength = arr.length
for (let i = 0; i < 6; i++) {
const remainder = i % arrLength
console.log(`i = ${i}, remainder = ${remainder}`)
console.log(`arr[remainder] = ${arr[remainder]}`)
}
```

This prints:

```
i = 0, remainder = 0
arr[remainder] = 1
i = 1, remainder = 1
arr[remainder] = 2
i = 2, remainder = 2
arr[remainder] = 3
i = 3, remainder = 0
arr[remainder] = 1
i = 4, remainder = 1
arr[remainder] = 2
i = 5, remainder = 2
arr[remainder] = 3
```

You can see that, even though `i`

continues to increase, the remainder resets itself after reaching a multiple of the array’s length. In that way, you can continue to wrap around the array without worrying about resetting or decrementing `i`

.