I’m developing a projet in C++ where results are print on the std::cout like that :
std::cout << std::setprecision(5) << "UNDERLYING=" << v_underlying << '\n';
std::cout << "RESULT=" << v_result << '\n';
which gives :
UNDERLYING=1.2454
RESULT=0.000054785
But for an unknow reason, when I launch the program of the computer of my team partner, the output is like that :
UNDERLYING=1.2454
RESULT=5.4785e-031
we are under windows 7 X64 bits so do you know if there is an option to change under Windows or the problem comes from the code ?
Use
std::cout << std::fixed;to specify output format