Check it out in the later pages of the A.O.A. book 2, and read PH' original method for the marble mystery, you will be completely gobsmacked at the method.
Sorry, just thought I would say this as seeing PH's method, will help you broaden the way you think about this whole "puzzle" so to...