/* Isascii (whether the test character is an ASCII character) function iscntrl header file # include <ctype. h> defines the int isascii (INT c) function. Function Description checks whether the parameter C is an ASCII character, that is, whether the range of C is between 0 and 127. Returns true if the parameter C is an ASCII character; otherwise, returns NULL (0 ). This is a macro definition, not a real function. Example * // * determines whether int I has an ASCII character mapped */# include <stdio. h> # include <ctype. h> main () {int I; for (I = 125; I <130; I ++) if (isascii (I) printf ("% d is an ASCII character: % C \ n ", I, I); else printf (" % d is not an ASCII character \ n ", I);}/* run the 125 is an ASCII character :} 126 is an ASCII character :~ 127 is an ASCII character: 128 is not an ASCII character129 is not an ASCII character */
Isascii (test whether the character is an ASCII character)