int main() { char str[] = "1A2B.g0v"; for (int i=0; i< strlen(str); i++) if ( isDigit(str[i]) ) cout << "True" << endl; else cout << "False" << endl; return 0; }