Returns the index value of the first occurrence of a
string within another
Find the first occurrence of “e” within “Hello”
This example returns a 1 (zero offset).
find(string s find, string expr field)
- s: string to search for
- field: string to be searched
Both s and field are expressions evaluating to the
find returns the offset in the
string field where s can be found. The offset is the index of the first character where the match is found. If there is no match,
find returns -1.