Hard
Remove Duplicate Lines
Write the input lines (until END) to a file. Create a new file with duplicate lines removed (keep the first occurrence) and print it, then the number of lines removed.
Input
Lines, then END.
Output
Unique lines, then a count.
Sample 1
Input
a b a c b END
Output
a b c 2
Sample 2
Input
x END
Output
x 0
Output appears here