There is no "it". There is only default format and ways to modify it.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
#include <iostream> // std::cout, std::fixed
#include <iomanip> // std::setprecision
#include <cstdlib> // atof
#include <string> // std::stod
int main () {
double f = 3.1415926;
double g = atof("3.1415926");
double h = std::stod("3.1415926");
std::cout << f << " vs " << g << " vs " << h << '\n';
std::cout << std::setprecision(5) << f << " vs " << g << '\n';
std::cout << std::setprecision(10) << f << " vs " << g << '\n';
std::cout << std::fixed;
std::cout << std::setprecision(5) << f << " vs " << g << '\n';
std::cout << std::setprecision(10) << f << " vs " << g << " vs " << h << '\n';
return 0;
}
That being said, the binary floating point representation in memory has limits and is better to be described as "strange and weird" rather than as "accurate and intuitive".