help for saving vertical datas to horizontal with "awk" or "cut"

hi,
i have a file having datas like that

./a.txt
12344
12345
12346
12347
.....
.....
...

i want to save this datas to another file like that

./b.txt
12344 12345 12346 12347 ... ... ...

i think awk can make this but how? :slight_smile: waiting for ur help.

Try this

cat a.txt | xargs -n`cat a.txt | wc -l`

UUOC :wink:

@OP

tr '\n' ' ' < a.txt > b.txt

thank you :slight_smile: