indexOf() Example 2 This example defines an array [2, 5, 9, 2, 1, 9, 8, 9, 4, 9, 2, 9] and then returns the indices of the number 9 in the array.
This example defines an array [2, 5, 9, 2, 1, 9, 8, 9, 4, 9, 2, 9] and then returns the indices of the number 9 in the array.