Idea Ripper // ArchiveCards: 1555 [Live] | Updated: 2026-10-14
Card #c865IR // #c865Synthesis

When you have to check many things against many things, use a fast, cheap screen to rule out almost everything, then spend real effort only on the few that pass. Fingerprint first, inspect second.

— In our words · Source: Algorithms Every Programmer Should Know (Aniket Wattamwar)

[Use when]

You are searching or matching across a large set and the full check is slow or expensive.

[Why it matters]

Compare a quick fingerprint first; run the full, expensive check only when the fingerprint matches.

More from Algorithms Every Programmer Should Know

#c858Before you chase "better," name what you are giving up to get it. Speed costs money. Thoroughness costs time. Reach costs attention.…You are deciding between two "better" options and keep assuming one is best in every way, or someone promises… #c859When you plan a system, a launch, or a budget, design for the worst realistic case, because that is exactly where things break. The average…You are sizing a plan, a budget, or a capacity and someone says "on average it will be fine." #c860Do the crude version first, the one that just works, then improve it once you can see the real bottleneck. Optimizing before you have a…You are stuck planning the perfect approach, or someone wants to optimize a process that does not work yet.