Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

There's a slightly simpler solution if you don't care whether the odd ball is lighter or heavier:

It's:

X. AAAA vs BBBB

If X was balanced, XX: C1 vs C2, then XXX: C2 vs C3 (general way to distinguish 2 unknowns: weigh one unknown against one known)

If X was unbalanced, WLOG assume A was heavier. XY: A1 A2 B1 vs A3 A4 B2

Then if XY balanced, use the general method to distinguish B3 or B4 as answer.

If XY unbalanced, WLOG assume A1 or A2 is heavy, or B2 is light, so XYY A1 vs A2 finds the heavy one or implies B2 is light.



What is C1 and C2 and C3?

What is XY? What's WLOG?

Can you dumb this down a bit more please?




Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: