$ ./guess_the_languageRegex
Regex · easy · #3

What does this expression return?

'banana'.search(/an/)
  1. 1
  2. 2
  3. 3
  4. true
search returns the index of the first match; "an" first starts at index 1.
Play Regex ▸