Why use float and double instead of real?

Lars T. Kyllingstad public at kyllingen.NOSPAMnet
Tue Jun 23 05:44:31 PDT 2009


Is there ever any reason to use float or double in calculations? I mean, 
when does one *not* want maximum precision? Will code using float or 
double run faster than code using real?

I understand they are needed for I/O and compatibility purposes, so I am 
by no means suggesting they be removed from the language. I am merely 
asking out of curiosity.

-Lars


More information about the Digitalmars-d-learn mailing list