grep / uniq magic
uniq can compare stuff before / after N characters in the string, group together duplicate ones, etc!
uniq -w Nlooks at only the N first characters.
uniq -s Ndon’tt look at the first N characters
uniq --all-repeated[=METHOD]prints all duplicated lines and optionally separates them via METHOD.
separateis really nice as method.
uniq -cprefixes line by number of occurrences of that line
And I guess again -
uniq works only on sorted data.