I have many txt files in a folder. Each file contains one line in this format;
8852 0.53451 0.55959 0.65494 0.36047
I would like to add, in the next line, a fixed number and the rest 4 columns copying from the original line, like so
8852 0.53451 0.55959 0.65494 0.36047
9997 0.53451 0.55959 0.65494 0.36047
So far I managed to add 9997 by the below command inside the folder
find *.txt -exec sh -c 'echo "9997" >> $0' {} \;
and managed to copy the rest 4 columns by
for files in .; do awk '{$1=""; print substr($0,2)}' *.txt;done
but it prints out in the output and not in the next line in each file.
I haven't managed to put them together yet and felt like I come so close but maybe in a wrong direction. I tried awk '{print "\n"$2,$3,$4,$5}'but it also didn't work.
Any help is appreciated! Thank you.