Hi, Please help me with the following problem, thank you very much.
I know how to use atoi or strtod to convert string to number, however, if the number cannot be converted, the functions returns zero, what if the number is already 0, then I can't tell if that means it can't be converted or it's converted to 0
if I have a string "0.3.4" (it's meant to have only one numeric value in the string), which is not a valid number, how can I check that it is not a valid number?
thank you so much
I know how to use atoi or strtod to convert string to number, however, if the number cannot be converted, the functions returns zero, what if the number is already 0, then I can't tell if that means it can't be converted or it's converted to 0
if I have a string "0.3.4" (it's meant to have only one numeric value in the string), which is not a valid number, how can I check that it is not a valid number?
thank you so much