WLJS LogoWLJS Notebook

DigitQ

DigitQ[string] yields True if all characters in the string are digits 0-9, and False otherwise.

Examples

Test digit strings:

DigitQ["12345"]
(* True *)
DigitQ["12.34"]
(* False *)
DigitQ["abc"]
(* False *)

Please visit the official Wolfram Language Reference for more details.

On this page