I'm trying to convert a string to a float. I can successfully distinguish between numbers and letters BUT if I type in 0 I'm not sure what to do.
Code:string input; float x; char *end; cin >> input; x = strtof(input.c_str(),&end); if(x>0 || isZero(input)) //do thingsCode:bool isZero(string input) { //??? }