I am creating 1D and 2D array from a file that contains lines that look like this:
42857000 -923070 0 0 -7887
428570 -546190 -4285700 546190 0
-6.5 -0.15384 6.5 0.15384 0.007
0 0 42857000 360570 0
When I populate the arrays from the file, they get converted to scientific notation:
42857000 >>>>> 4.2857000e+007 etc!!!
Is there anyway to stop this?
My arrays are defined as follows:
float aMatrix[DEFROWS][DEFCOLS] = {0.0};
float bMatrix[DEFCOLS] = {0.0};
This issue is causing my app to crash.
Thanks.
I assume this is just from printing with
cout. If that’s the case, usestd::fixed: