use try and catch to tell if it is a float or not