+2 votes
in Programming Languages by (74.2k points)

I am running a python script to convert number string to float, but I am getting the following error:

ValueError: could not convert string to float:

1 Answer

+1 vote
by (71.8k points)
selected by
 
Best answer
Looking at your error message, it seems that the string you are converting to float is blank. If you try to convert SPACE to float, you will get this error. Check you code and make sure the string is not blank.

...