I'm running GAWK on WIN32 and I have a terrible problem with float precision.
I read from a file float numbers with 9 decimals, and I've checked it is ok. The problem is when I try to operate with them, because they become just 6 decimals precision.
What can I do?? I've tried with printf("%.8f",res) but it prints all the time "0.80.80.80.80.8...".
Here is my code. Thanks a lot!!
gawk "{post=$1}{print post-prev}{prev=$1}" myInput
I read from a file float numbers with 9 decimals, and I've checked it is ok. The problem is when I try to operate with them, because they become just 6 decimals precision.
What can I do?? I've tried with printf("%.8f",res) but it prints all the time "0.80.80.80.80.8...".
Here is my code. Thanks a lot!!
gawk "{post=$1}{print post-prev}{prev=$1}" myInput