ctype(3) Library Functions Manual ctype(3)
Name
isalpha, isupper, islower, isdigit, isxdigit, isalnum, isspace, ispunct, isprint, isgraph, iscntrl, isascii - character classification
macros
Syntax
#include <ctype.h>
int isalpha (c)
int c;
Description
These macros classify character-coded integer values according to the rules of the coded character set (codeset) identified by the last
successful call to category All macros return non-zero for true and zero for false.
If category has not been called successfully, or if character classification information is not available for a supported language, then
characters are classified according to the rules of the ASCII 7-bit coded character set, returning 0 for values above octal 0177.
The macro provides a result for all integer values. The rest provide a result for EOF and values in the character range of the codeset
identified by the last successful call to category
c is a letter
c is an uppercase letter
c is a lowercase letter
c is a digit
c is a hexadecimal digit, by default [0-9], [A-F], or [a-f]
c is an alphanumeric character
c is a space, tab, carriage return, new line, or form feed
c is a punctuation character (neither control, alphanumeric, nor space)
c is a printing character, by default code 040(8) (space) through 0176 (tilde)
c is a printing character, like except false for space
c is a delete character(0177) or ordinary control character (less than 040) except for space characters
c is an ASCII character, code less than 0200
International Environment
LC_CTYPE If this environment variable is set and valid, uses the international language database named in the definition to determine
character classification rules.
LANG If this environment variable is set and valid, uses the international language database named in the definition to determine
the character classification rules. If is defined, that definition supercedes the definition of
See Also
conv(3), setlocale(3), stdio(3s), environ(5int), ascii(7)
Guide to Developing International Software
ctype(3)