### 5.1.42 find

`Syntax:`
  `find (` string_expression`,` substring_expression `)`
  `find (` string_expression`,` substring_expression`,` int_expression `)`
`Type:`
  int
`Purpose:`
  returns the first position of the substring in the string or 0 (if not found),
  starts the search at the position given in the 3rd argument.
`Example:`

        find("Aac","a");
      ==> 2
        find("abab","a"+"b");
      ==> 1
        find("abab","a"+"b",2);
      ==> 3
        find("abab","ab",3);
      ==> 3
        find("0123","abcd");
      ==> 0

See string.

User manual for Singular version 4.4.1, 2025, generated by texi2html.