How to delete every other line in a file?# Unix - 噫吁兮,危乎高哉
s*d
1 楼
Got big data files, need to extract some of them, say delete every other line
what's the easiest way to achieve it?
I currently use this way:
$ gawk '(NR%2)==0' file >newfile
what's the easiest way to achieve it?
I currently use this way:
$ gawk '(NR%2)==0' file >newfile