Problem

Return s.indexOf('x').

Examples

  • indexOfX("extra") -> 2
  • indexOfX("abc") -> -1
Compile and test (Ctrl+Enter)