411 REFERENCE · Wikibooks
C++ Language/Std/Strings/CharacterCategories
Reference material by Wikibooks contributors. This retains its source identity and is not 411 news reporting.
There are functions for classifying a character as belonging to a category.
The examples isdigit('0'), isspace(' '), and ispunct('!') all return true (in the form of a non-zero int value).
Additional information about character categories (includes interactive examples)