Three-List Comparer

Compares three separator-delimited lists and reports items common to all three, items present in exactly two of the three, and items unique to exactly one list, the three-list generalization of List Comparer. A free online tool from Staaarter, right in your browser.

Runs locallyUpdated 2026-07-27

Overview

Introduction

Comparing three related lists at once, for example three different exports of the same dataset, quickly becomes hard to reason about with only pairwise comparison tools.

Three-List Comparer classifies every value across all three lists in one pass by how many of the three lists it appears in.

What Is Three-List Comparer?

A three-list set comparison tool: it computes, for every distinct value across all three lists, whether it appears in all three, exactly two, or exactly one.

It's the natural three-way generalization of List Comparer, replacing three separate pairwise comparisons with a single combined report.

How Three-List Comparer Works

All three inputs are split into items using the shared selected separator, each forming a set of distinct values.

Every distinct value across the union of all three sets is classified by counting how many of the three sets contain it, then grouped into the all-three, exactly-two, and unique-to-one sections.

When To Use Three-List Comparer

Use it to find values consistent across three data sources versus values that only partially agree.

It's useful for reconciling three versions of a list, for example three team members' independently compiled tag lists.

Features

Advantages

  • Classifies every value's membership across all three lists in a single pass, instead of three separate pairwise comparisons.
  • Preserves first-seen order across the combined lists within each output section.

Limitations

  • The "exactly two" section doesn't identify which specific pair of lists shares each value.
  • Comparison is exact and case-sensitive with no trimming applied.

Examples

Three overlapping lists

Input

List A: a, b, c
List B: b, c, d
List C: c, d, e

Output

In all three: c
In exactly two: b, d
Unique to one: a, e

"c" appears in all three lists, "b" and "d" each appear in exactly two, and "a"/"e" each appear in only one list.

No values shared by all three

Input

List A: x, y
List B: y, z
List C: z, w

Output

In exactly two: y, z
Unique to one: x, w

No value appears in all three lists, so the "in all three" section is empty while the other two sections still populate normally.

Best Practices & Notes

Best Practices

  • Use List Comparer instead when you only have two lists, since its two-section-plus-both output is simpler to read.
  • Follow up with a pairwise List Comparer run if you need to know exactly which two lists share an "exactly two" value.

Developer Notes

Builds three `Set<string>` objects and a combined first-seen-order array from all three inputs' items, then classifies each distinct value by summing three `.has()` boolean checks (`setA.has(x) + setB.has(x) + setC.has(x)` conceptually) into a 1, 2, or 3 count.

Three-List Comparer Use Cases

  • Reconciling three independently compiled versions of the same list
  • Finding values that only partially agree across three data exports
  • Auditing consistency across three related datasets in one pass

Common Mistakes

  • Expecting to see which specific pair of lists an "exactly two" value came from; that detail isn't broken out.
  • Forgetting all three lists share one separator setting.

Tips

  • If a value is missing from the "in all three" section unexpectedly, check for stray whitespace or casing differences across your three lists.
  • Chain the "in all three" section into another list tool once you've confirmed full agreement.

References

Frequently Asked Questions