1//The general syntax for this method is:
2arrayName.indexOf(item)
3
4/*This method returns the index of the FIRST occurence of an item in
5the array. If the item is not in the array, -1 is returned.*/
6
7let charles = [1, 7, 5, 9, 5];
8let otherArray = ['hello', 'world!'];
9
10console.log(charles.indexOf(5));
11
12console.log(otherArray.indexOf('hi'));
13
14//2
15//-1