cpp/string/basic string/find

Finds the first substring equal to the given character sequence. Search begins at, i.e. the found substring must not begin in a position preceding.

@1@ Finds the first substring equal to.

@2@ Finds the first substring equal to the range. This range may contain null characters.

@3@ Finds the first substring equal to the character string pointed to by. The length of the string is determined by the first null character using.

@4@ Finds the first character (treated as a single-character substring by the formal rules below).

@5@

Formally, a substring is said to be found at position  if all of the following is true:
 * for all positions in,.
 * for all positions in,.
 * for all positions in,.

In particular, this implies that
 * a substring can be found only if
 * an empty substring is found at if and only if
 * for a non-empty substring, if, the function always returns npos.

Return value
Position of the first character of the found substring or npos if no such substring is found.

Exceptions
@1-4@ Throws nothing. @5@