$ ./guess_the_languageProblem Solving — fill the blank
Problem Solving — fill the blank · easy · #175

What goes in the blank?

// index of the first match, or -1
const i = rows.____((r) => r.ok);

Answer: findIndex (also accepted: findIndex, findIndex())

findIndex() returns the position, while find() returns the element.
Play Problem Solving ▸