awk - How to copy numeric data from file to array in Linux -


i have data in output.txt shown below. wanted copy data file array in linux. wanted using awk.

3.2222196800737746e-01 9.0625504539639357e-02 -4.4309220157707685e-01 7.6522564411406657e-01 -7.1683767983542657e-01 4.8589460714063371e-01 -2.5294463208548001e-01 2.8153758928251349e-01 -1.9848560597677056e-01 

you this:

arr=($(cat output.txt)) echo ${arr[0]} 3.2222196800737746e-01  echo ${arr[2]} -4.4309220157707685e-01 

first data stored in slot 0 second in slot 1 etc.


Comments

Popular posts from this blog

how to proxy from https to http with lighttpd -

android - Automated my builds -

python - Flask migration error -