I have some data in this form (3 columns) stored in the variable ABC
:
d1 d2 d3
d4 d5 d6
d7 d8 d9
d10
and I would like to format it in this form (4 columns):
d1 d2 d3 d4
d5 d6 d7 d8
d9 d10
I've tried something like this:
printf "%8.3e %8.3e %8.3e %8.3e\n" "${ABC}"
but it doesn't work. Can anyone see where the problem is?