Name

findfirstof — Find position of first matching charachters in string

Synopsis

integer findfirstof ( string  STRING ,
  string  CHARS );

Parameters

string STRING

string CHARS

Charachters to find

Return

integer

the position of the first character in STRING that is contained in CHARS.

Description

The `findfirstof' function searches string for the first match of any character stored in chars and returns its position.

If no match is found findfirstof returns `nil'.

Usage

  findfirstof ("abcdefghi", "cxdv") -> 2
  findfirstof ("aaaaa", "z") -> nil