On 2/2/19 6:21 AM, Brad Gilbert wrote:
`.index` is going to be the fastest because it is directly using NQP
ops which are built into the VM.
'abcdefg'.index('de'); # 3
If you want all of the indexes, use `.indices`
'abcdefabc'.indices('abc'); # 0, 6
`.index` will return `Nil` if it
`.index` is going to be the fastest because it is directly using NQP
ops which are built into the VM.
'abcdefg'.index('de'); # 3
If you want all of the indexes, use `.indices`
'abcdefabc'.indices('abc'); # 0, 6
`.index` will return `Nil` if it doesn't find anything, and `.indices`
will