tests a character to see if it is alphanumeric
#include <ctype.h> int isalnum( int c );
The isalnum() function tests if the argument c is an alphanumeric character ('a' to 'z', 'A' to 'Z', or '0' to '9'). An alphanumeric character is any character for which isalpha() or isdigit() is true.
The isalnum() returns zero if the argument is neither an alphabetic character nor a digit. Otherwise, a non-zero value is returned.
isalpha(), isdigit(), islower()
#include <stdio.h> #include <ctype.h> void main() { if( isalnum( getchar() ) ) { printf( "is alpha-numeric\n" ); } }
ANSI
All (except DOS/PM)