C + + inherits from the C language a character-related, very handy function package that simplifies such things as determining whether characters are uppercase, numeric, punctuation, and so on, which are defined in the header file Cctype (old style ctype.h).
The following table summarizes these functions, some of which may not have the functions listed in the table, or some functions that are not listed in the table.
| Function name |
return value |
| Isalnum () |
If the argument is an alphanumeric character, that is, a letter or a number, the function returns True |
| Isalpha () |
If the argument is a letter, the function returns True |
| Iscntrl () |
If the argument is a control character, the function returns True |
| IsDigit () |
If the argument is a number (0~9), the function returns True |
| Isgraph () |
If the argument is a print character other than a space, the function returns True |
| Islower () |
If the argument is a lowercase letter, the function returns True |
| Isprint () |
If the argument is a print character (including a space), the function returns True |
| Ispunct () |
If the argument is a punctuation mark, the function returns True |
| Isspace () |
If the parameter is a standard white space character, such as a space, feed, line break, carriage return, horizontal tab, or Vertical tab, the function returns True |
| Isupper () |
If the argument is an uppercase letter, the function returns True |
| Isxdigit () |
If the argument is a hexadecimal number, that is, 0~9,a~f or a~f, the function returns True |
| ToLower () |
If the argument is an uppercase character, it is returned in lowercase, otherwise the parameter is returned |
| ToUpper () |
If the argument is a lowercase character, it is returned in uppercase, otherwise the argument is returned |
| ... |
|