learnprogramming123

LEARN PROGRAMMING 123
your resources to programming and free tutition



Navigation

 
C
 
C++ soon here!
VB - soon here!

Search

 

 

Next Back

 

<ctype.h>        -        Character handling

The header contains functions for testing and converting characters. In the following list, the declaration of each function is followed by a description of the value returned by each function. Note - a return value of !=0 (non-zero) implies true when used in a conditional statement.

1 int isalnum(int c); !=0 if c is an alphanumeric character in range 'A'-'Z', 'a'-'z', '0'-'9'
2 int isalpha(int c); !=0 if c is an alphabetic character is range 'A'-'Z', 'a'-'z'
3 int iscntrl(int c); !=0 if c is a control character in range 0x0-0x1F or 0x7F
4 int isdigit(int c); !=0 if c is a digit in range '0'-'9'
5 int isgraph(int c); !=0 if c is a printable character (excluding space) in range 0x21-0x7E
6 int islower(int c); !=0 if c is lower case letter in range 'a'-'z'
7 int isprint(int c); !=0 if c is a printable character in range 0x20-0x7E
8 int ispunct(int c); !=0 if c is a punctuation character in range 0x21-0x2F, 0x3A-0X40, 0X5B-0X60, 0X7B-0X7E
9 int isspace(int c); !=0 if c is a white space character in range 0x9-0xD or 0x20
10 int isupper(int c); !=0 if c is upper case letter in range 'A'-'Z'
11 int isxdigit(int c); !=0 if c is a hexadecimal digit in range '0'-'9', 'A'-'F', 'a'-'f'
12 int tolower(int c); return lower case value of character c in range 'a'-'z'
13 int toupper(int c); return upper case value of character c in range 'A'-'Z'
     

go to <errno.h>         back to top        back to main