should I use float or double in c++ code example
Example 1: double to float c++
double v1 = 20120313.0;
float v2 = (float) v1;
Example 2: float in c++
float contains less storage than a double.
float p = 25.0;
double p = 25.0;
double v1 = 20120313.0;
float v2 = (float) v1;
float contains less storage than a double.
float p = 25.0;
double p = 25.0;