I was wondering when would a float be used rather than a double? Isn't a double just a more precise version of a float? So besides for memory purposes why wouldn't you always use a double for more accurate answers?
Sometimes a more precise answer is not required and some other thing takes precedence. For example using a float may be a little faster, quite often floats are used in games because of this fact. Also there are situations where size is of primary importance. For example when working with memory constrained embedded systems or very large arrays/vectors.