Hello,
I wrote a script that does lot of things, and I would like to change the format of a number but without printing it now (so I don't want to use printf as it will print the value immediately).
Schematically here is what I have:
awk 'BEGIN{number=0.01234567}
$1==$2{$3=number}
{print}' myfile
I would like to have my output with the format 1.234567E-02, but of course the BEGIN part cannot be changed. The problem with using printf is that the lines matching $1==$2 don't have all the same number of elements, or the same spacing...
Every suggestion is very welcome.
Thanks