3 ms·
You should mention this behavior of uniq (from the man page on my machine): Note: ’uniq’ does not detect repeated lines unless they are adjacent. You may wan
by aabaker99 12y ago
You should mention this behavior of uniq (from the man page on my machine):
Note: ’uniq’ does not detect repeated lines unless they are adjacent. You may want to sort the input first, or use ‘sort -u’ without ‘uniq’.
Your movies.csv file is already sorted, but you don't mention that sorting is important for using uniq, which may be misleading.
$ cat tmp.txt
AAAA
AAAA
BBBB
DDDD
BBBB
$ uniq -d tmp.txt
AAAA