DIY: Valid Number
Problem statement
Validate if a given string can be interpreted as a decimal number or not. Here is a list of characters that can appear in a valid decimal number:
-
Numbers -
0-9
-
Exponent -
"e"
-
Positive/negative sign -
"+"/"-"
...
Create a free account to view this lesson.
By signing up, you agree to Educative's Terms of Service and Privacy Policy