4,000 lines in the file. 12 distinct messages inside them. A raw line count hands you the first number and hides the second, and the second is the one that matters when you are trying to work out what a service actually did overnight. The Line Counter reports both, breaks the gap between them out as a duplicate count, and puts a View Unique Lines toggle underneath that produces the deduplicated list itself.
Uniqueness is judged on the trimmed line. Two entries differing only by trailing whitespace therefore count as one, which is nearly always what you want from a pasted list and the reason the unique figure can come in lower than a character-for-character comparison would suggest. Two further cards report the longest line and the mean line length, in characters.
The stat grid appears only once something is in the box. Every figure recalculates on each keystroke. The counting is a split and a Set built in the page, so nothing is uploaded.
Getting a Deduplicated List Out of a Paste
- Drop your lines into the box. All 7 stat cards appear as soon as the first character lands.
- Read Total Lines against Unique Lines. When they match there is nothing to remove and the rest of this is unnecessary.
- Press View Unique Lines. A read-only monospace pane opens below holding one copy of each line, in the order each first appeared.
- Press Copy Unique. That pane drops blank lines entirely, so the copied list is shorter than the Unique Lines figure whenever your input contained any.
- Press Hide Unique Lines to collapse the pane, or the circular arrow at the top right of the input to clear the lot.
Precision of the Unique and Duplicate Counts
- Blank lines are a value like any other. Ten empty lines contribute 1 to Unique Lines and 9 to Duplicate Lines, which is why the duplicate figure runs high on a double-spaced document.
- Duplicate Lines is total minus unique, not the number of lines that have a twin. Three copies of one line register as 2 duplicates.
- Comparison is case-sensitive, so
ERROR and error occupy two slots in the unique count. - Longest Line measures the untrimmed line in UTF-16 code units, so an emoji adds 2 to that figure while a tab adds 1.
- Avg Line Length divides total characters by total lines with blank lines included, rounded to one decimal. A document padded with blank lines reports a shorter average than its prose alone would.