Skip to content
Advertisement

How do i filter out category and header and get the index of array of filtered tabs?

Below are the given input

JavaScript

Below is the array that needs to be filtered

JavaScript

Output (Index of Lamb chops)

JavaScript

Advertisement

Answer

JavaScript

This function should return -1 when no matching values found.

User contributions licensed under: CC BY-SA
4 People found this is helpful
Advertisement