awk - add column of 1's to tab-delimited file -
can't find solution, though thousands of variations of question have been asked.
i want add column of 1's tab-delimited file using awk or sed.
the file have 20 million lines, efficient nice.
turn this:
a b c r j k t w
into this:
a b c 1 r j k 1 t w 1
assuming used awk -f'\t'
instead of awk
:
{ print $0 fs 1; }
if didn't use -f option, replace fs 1
"\t1"
.
Comments
Post a Comment