decimal number

hey,
i want to know how to show more than 6 numbers after the comma in a float number .
1
2
3
4
5
#include <iomanip>
//...
std::cout << std::fixed; //Make output stream use fixed point and not exponential representation
std::cout << std::setprecision(10); //Set how many digits after decimal point to show.
//There is no reason to set it higher than 10 for floats and 14 for doubles as other digits would be incorrect anyway. 
Last edited on
i did that but it don't work! this is a part of my program and i don't know where i can add the function that you told about.

...
ofstream out ("output.txt");

...

std::norm(R);
out<<norm(R)<<endl;
}

out.close();

return 0;
}
i did that

Where? I don't see MiiniPaa's suggested code in what you posted.
Topic archived. No new replies allowed.