Answers for "can you use indexof to find an array within an array"

7

js get index of item in array

array.indexOf("item");
Posted by: Guest on May-13-2020
0

Find the index of an item in the Array

fruits.push('Mango')
// ["Strawberry", "Banana", "Mango"]

let pos = fruits.indexOf('Banana')
// 1
Posted by: Guest on July-02-2021

Code answers related to "can you use indexof to find an array within an array"

Code answers related to "Javascript"

Browse Popular Code Answers by Language