How to use this tool
- Enter your lines.
- Select Update result to view the result.
- Check the method and assumptions below before using the result.
Input reference and sample values
Use the units and choices shown for each field. Sample values are provided for practice, not as recommendations.
| Input | Format and units | Sample |
|---|---|---|
| Your lines | Keep the structure and separators shown in the sample. Line breaks are retained in this input. | apple
orange
apple
pear |
Result for these sample inputs
apple orange pear
- Lines removed
- 1
- Unique lines
- 3
Select Try the example in the form to load these values and calculate them again. This replaces the current form inputs. Compare the result with the method and worked explanation below.
The method, explained
Split text into lines, keep the first occurrence of each exact line, and join the remaining lines in the original order.
The lines apple, orange, apple, pear become apple, orange, pear.
What to keep in mind
Comparison is case-sensitive and preserves leading or trailing spaces. Repeated blank lines are also deduplicated.
Common questions
Are Apple and apple duplicates?
No. This tool treats uppercase and lowercase letters as different.
Does it sort the lines?
No. The first occurrence stays in its original order.
Methodology maintained by ClarityKit. How these tools are built and checked.