There is an input that I need to read from the console as a string, then manipulate the string and convert some of it to float32
.
I have tried using:
float, _ := strconv.ParseFloat(myString, 32)
But it does not work. This is the error I get:
cannot use float (type float64) as type float32 in field value
Is there anything else I could do? Thanks!