I have a csv file with duplicate lines and I need to extract only the non repeating lines.
For example, I have
12
13
14
12
13
15
and the desired output is:
14
15
I have a csv file with duplicate lines and I need to extract only the non repeating lines.
For example, I have
12
13
14
12
13
15
and the desired output is:
14
15
To find the unique lines in a file you can use
uniq -u
(required sorted file):An alternative method using
awk
: