Problem

Return first index of target or -1.

Examples

  • firstIndexOf([4, 5, 4], 5) -> 1
Compile and test (Ctrl+Enter)