Practice this fail.
Duplicates, now adjacent.
Linux · Restart as often as you like
Read the error, choose a command, and learn
why it works. Nothing runs on your machine.
tags.txt contains duplicate full lines in arbitrary order. Produce sorted unique output using one GNU sort command; leave the file unchanged.
Duplicates, now adjacent.
$ uniq tags.txt
blue red blue
How do you deduplicate lines regardless of their original position?
Fixed. By hand.
sort -u tags.txtsort -u orders the lines and outputs one representative of each equal group. Unlike uniq on unsorted input, it can remove duplicates that started far apart.
Practice does not affect your daily score or streak.