In C ++, the string class member function find_first_not_of ()
Function prototype:
# Include <string>
Size_type find_first_not_of (const string & STR, size_type Index = 0) const;
Size_type find_first_not_of (const char * STR, size_type Index = 0) const;
Size_type find_first_not_of (const char * STR, size_type index, size_type num) const;
Size_type find_first_not_of (char CH, size_type Index = 0) const;
The find_first_not_of () function is as follows:
1. Return the first character index that appears for the first time in a string that does not match any character of str. Search from index. If all matches, return string: NPOs.
2. start from index to search for the current string. Search for any of the strings that do not match the num character before Str. The first character index that meets the conditions is returned. Otherwise, the string :: NPOs.
3. Return the first index in the current string that does not match the CH character. Search from the index. If no result is returned, return string: NPOs.
Note: The string class defines NPOs as greater than any valid value. NPOs =-1 indicates the end of the string index number. Or the index number is invalid. Failed to find