12.3. Searching

In this section, we’ll take a look at how to search for a value in an array. You will learn about linear search and binary search.

Note

namespace

Note that to use the example files downloaded from GitHub, you need to keep the namespace consistent. It is recommended to use IntroCSCS (or IntroCS) and you have to check every file to make sure they are consistent. Failing to do so will incur an error “error CS0103: The name ‘CLASS’ does not exist in the current context”.